Re: [h2] Function to output text?

2014-09-04 Thread Gili
Actually, no. This doesn't work. There is no such method :) There is java.lang.System.out.println but of course H2 won't accept: CREATE ALIAS println FOR "java.lang.System.out.println"; because: org.h2.jdbc.JdbcSQLException: Class "java.lang.System.out" not found; SQL statement: But I get yo

Re: [h2] Function to output text?

2014-09-04 Thread Gili
Excellent. Thanks ;) Gili On Friday, September 5, 2014 1:58:54 AM UTC-4, Noel Grandin wrote: > > CREATE ALIAS PRINTLN FOR "java.lang.System.println"; > > CALL PRINTLN("") > > On Fri, Sep 5, 2014 at 3:37 AM, Gili > wrote: > > Hi, > > > > Is there a built-in println function of sorts?

Re: [h2] Function to output text?

2014-09-04 Thread Noel Grandin
CREATE ALIAS PRINTLN FOR "java.lang.System.println"; CALL PRINTLN("") On Fri, Sep 5, 2014 at 3:37 AM, Gili wrote: > Hi, > > Is there a built-in println function of sorts? > > For example, I'd like to able to print out the values of @variables at > different points of an SQL script, or pr

Re: [h2] SCOPE_IDENTITY() returning NULL

2014-09-04 Thread Gili
Noel, I think you were wrong about this only working for sequences. I ran into http://stackoverflow.com/a/12319823/14731 which states that SET resets the value of SCOPE_IDENTITY() and provides a workaround (which worked for me). Is there an open bug report for the fact that SET should not reset

Re: [h2] SCOPE_IDENTITY() returning NULL

2014-09-04 Thread Gili
To be clear, I believe my definition of SCOPE_IDENTITY() is a function that returns the same value as http://docs.oracle.com/javase/7/docs/api/java/sql/Statement.html#getGeneratedKeys() Gili On Friday, September 5, 2014 12:52:15 AM UTC-4, Gili wrote: > > On second thought I think this issue sho

Re: [h2] SCOPE_IDENTITY() returning NULL

2014-09-04 Thread Gili
On second thought I think this issue should be reopened. 1. The microsoft documentation doesn't say this function is limited to sequences. I think it should work on all tables. 2. I need a way to get the AUTO_INCREMENT column of a row I just inserted, but my triggers are causing IDE

[h2] Re: MySQL User Variable Assignment Syntax

2014-09-04 Thread Gili
Hi Thomas, Can you please document this syntax? The documentation should mention that SELECT SET(@variable, column_name) is now supported. Thanks, Gili On Friday, April 18, 2008 4:16:55 PM UTC-4, skyfox01_99 wrote: > > Hi Thomas, > > Thanks for the response. > > > I will add this to the roadm

[h2] Improving error message for value out of bounds

2014-09-04 Thread Gili
Hi, I'd like to propose improving the following error message: org.h2.jdbc.JdbcSQLException: Numeric value out of range: "-2147483606"; SQL statement: INSERT INTO department (name, company_id, owner_id, view_id, edit_id, delete_id, version, last_modified) VALUES ('Gaming', @company_id, @admin_i

[h2] Function to output text?

2014-09-04 Thread Gili
Hi, Is there a built-in println function of sorts? For example, I'd like to able to print out the values of @variables at different points of an SQL script, or print out the values returned by an SQL statement (again from within an SQL script). Thanks, Gili -- You received this message becau

Re: [h2] H2 db getting corrupt on mac

2014-09-04 Thread Kam
Testing the backup sounds like a good idea. thanks. Still not sure what would cause a corrupt db because if it happens while its in use, then this is not a solution but it's a start. -- You received this message because you are subscribed to the Google Groups "H2 Database" group. To unsubscri

[h2] Performance while doing join

2014-09-04 Thread Himanshu Jain
Hi All, I have a doubt, Can anybody of you clarify ? ->I have two tables each having around 1 million records. How much time it will take to do join operation in these 2 tables? Thanks, Himanshu -- You received this message because you are subscribed to the Google Groups "H2 Database" group.

[h2] Convert h2 DB to MySQL - gerrit migration

2014-09-04 Thread Fabien Bagard
Hi, I have a gerrit install running with H2. I set up another gerrit server with MySQL, and now I want to populate MySQL DB with H2 datas. Here is what I did : On mysql server 1. java -jar gerrit.war init -d /home/gerrit On h2 server 2. dump of H2 with java -cp h2-1.3.175.jar org.h2.tools.Scr

[h2] H2 to MySQL / Gerrit

2014-09-04 Thread Fabien Bagard
Hi, I have a gerrit instance running with an h2 database. It is time for me to move to a new server with mysql database. Here is what I did. On the mysql server : 1. Initialisation of database scheme with java -jar gerrit.war init -d /home/gerrit On the H2 server : 2. Get a backup of the DB co

Re: [h2] H2 1.4.181 system column _ROWID_ slow with MVSTORE

2014-09-04 Thread Nicolas Fortin (OrbisGIS)
Hi, Thanks for the patch Thomas. I will test it as soon as the snapshot build will be available. -Nicolas Le mercredi 3 septembre 2014 10:16:21 UTC+2, Nicolas Fortin (OrbisGIS) a écrit : > > Hi, > > Nice thank you ! > > We will give you more feedback later about the beta version of h2. > > Reg

Re: [h2] Support for BigDecimal extensions

2014-09-04 Thread Andrea Panattoni
Hi, I'm working on a large legacy codebase and for some strange reason a subclass of BigDecimal is used. It seems to be important. The code is compatible with SqlServer, Oracle and SAP Hana and all vendors are compatible with the subclass. It would be very useful to use H2 for testing. I thin