Re: Add alias "CEIL" for function "CEILING"

2011-05-06 Thread Thomas Mueller
Hi, Your are right, most databases support CEIL and LN. Those functions will be supported in the next version of H2 as well. Regards, Thomas -- You received this message because you are subscribed to the Google Groups "H2 Database" group. To post to this group, send email to h2-database@google

Re: in-memory h2 db performance

2011-05-06 Thread Thomas Mueller
Hi, > Is there anyway to use same connection without trying to get the connection > every time in the spring? I know it is outside but if you know please let me > know. You should use a 'real' connection pool. See http://static.springsource.org/spring/docs/2.5.x/api/org/springframework/jdbc/dat

Parsing SQL

2011-05-06 Thread IanP
I need to parse out the table names and column names from SQL statements that are entered by my users, as I need to check that the SQL conforms to certain conventions. One specific use case is in some circumstances they must select a column with an alias of ID and they must select a column with an

Re: sorting using ICU4J - patch

2011-05-06 Thread Thomas Mueller
Hi, Support for ICU4J is now committed in the trunk. Regards, Thomas -- You received this message because you are subscribed to the Google Groups "H2 Database" group. To post to this group, send email to h2-database@googlegroups.com. To unsubscribe from this group, send email to h2-database+u

Re: Automatic migration does not start if "h2.baseDir" system property is used

2011-05-06 Thread Thomas Mueller
Hi, I'm sorry for the delay. I have a reproducible test case, and I tried to fix the problem, but unfortunately it's not so easy... I believe it would require a change in the migration jar file. This is problematic however. I'm afraid the only solution I have for now is to not use the system prop

Re: Parsing SQL

2011-05-06 Thread Andreas Henningsson
My guess is that the H2 parser is a bit to dependent on other stuff be usabe alone. But you might can use parts of it and create your own parser. A more simple one. Here is the code: http://code.google.com/p/h2database/source/browse/trunk/h2/src/main/org/h2/command/Parser.java /Andreas On Fri,

Re: Option DROP of SCRIPT command

2011-05-06 Thread Thomas Mueller
Hi, If you have a _concrete_ problem please tell us what it is. Just saying "it does not know how to order the drop statements properly" isn't helpful. Regards, Thomas -- You received this message because you are subscribed to the Google Groups "H2 Database" group. To post to this group, send

Re: Require help

2011-05-06 Thread Thomas Mueller
Hi, Just curious: a "lac" is 100'000, right? I'm afraid with the data provided I can't help much. Did you already read: http://h2database.com/html/performance.html#explain_plan http://h2database.com/html/performance.html#storage_and_indexes http://h2database.com/html/performance.html#application

Re: DatabaseEventListener#init(url) - URL is null

2011-05-06 Thread Thomas Mueller
Hi, I can't reproduce the problem. In my test case, the database URL is correct. I wonder if the database event listener is the right tool for what you need. By the way, the script in INIT=RUNSCRIPT ... might be in the classpath using the resource URL: http://h2database.com/html/advanced.html#file

Re: H2 deadlock with 1.3.154

2011-05-06 Thread Thomas Mueller
Hi, I think this is the same as this issue, which is now fixed in the trunk: http://code.google.com/p/h2database/issues/detail?id=315 Regards, Thomas -- You received this message because you are subscribed to the Google Groups "H2 Database" group. To post to this group, send email to h2-databa

Re: Why isn't it possible to AUTO_SERVER an in-memory database

2011-05-06 Thread Thomas Mueller
Hi, > I checked the documentation and I can't find a place where we explain that. I'm not sure if you talk about the auto-server mode or the in-memory database. Auto-server mode: http://h2database.com/html/features.html#auto_mixed_mode (I will try to extend the documentation to be more clear, it

Re: how to get db url after startup

2011-05-06 Thread Thomas Mueller
Hi, > But I want to find it at shell prompt. The URL isn't available using SQL statements. However, you might be able to re-construct it using "select database_path()" - see also http://h2database.com/html/functions.html#database_path Regards, Thomas -- You received this message because you ar

Re: db gets lock

2011-05-06 Thread Thomas Mueller
Hi, To find out why a process is blocked, I usually use: jps -l (to get the process id) jstack -l (to get the full thread dump) Regards, Thomas -- You received this message because you are subscribed to the Google Groups "H2 Database" group. To post to this group, send email to h2-database@g

Re: join on 2 csv files

2011-05-06 Thread Thomas Mueller
Hi, > select * from csvread('secfile.csv') b  inner join > csvread(firstfile.csv') a on b.col1=a.col1 order by a.col1 This will read the file 'secfile.csv' once, but the file 'firstfile.csv' is read once _for every row_ in the other file. For performance reason, CSVREAD should not be used inside

Re: Unique Database/Catalog Name

2011-05-06 Thread Thomas Mueller
Hi, > Is there a way to get a unique database or catalog name? This might also help: "select database_path()". Regards, Thomas -- You received this message because you are subscribed to the Google Groups "H2 Database" group. To post to this group, send email to h2-database@googlegroups.com. T

Re: How to manually migrate from 1.1.127 to 1.2.147 ?

2011-05-06 Thread Thomas Mueller
Hi, In addition to what Anthony wrote, you might also be interested in: http://h2database.com/html/advanced.html#database_upgrade Regards, Thomas -- You received this message because you are subscribed to the Google Groups "H2 Database" group. To post to this group, send email to h2-database@g

Re: Option DROP of SCRIPT command

2011-05-06 Thread Rami Ojares
Well, the concrete problem is that I do a backup with script command using the drop option. And even with fairly simple databases when trying to restore the database, restore operation exits because it is unable to execute those drop statements because of dependency issues. Hasn't this happened to