[h2] Re: Cannot connect to an existing embedded database

2014-05-21 Thread too
hi,
Just few tips

   - what error is in OpenConcerto.trace.db?
   - try to create some table using the console. does that work? error?
   - what happens if you move the DB to location without spaces?
   - have you experimented with permissions to the DB file?

Tono

On Tuesday, May 20, 2014 5:47:15 PM UTC+2, Ospeleo wrote:

 Hi,
 What is wrong in my process ? 
 I need an outside view.
 I've been investigating this error for 12 hours over 3 days, thought it 
 was linked with my software which uses the H2 database (Openconcerto) but 
 it seems it is more H2/environment-related

 I use OSX10.6.8
 java version 1.6.0_65
 h2-1.3.176.jar

 I have a database (10mB) in 
 olivier:~ moi$ cd Library/Application\ Support/OpenConcerto/DBData/
 olivier:DBData moi$ ls -la
 total 19552
 drwxr-xr-x   4 moi  moi   136 19 mai 21:18 .
 drwxr-xr-x  24 moi  moi   816 19 mai 17:56 ..
 -rw-r--r--   1 moi  moi  10004480 19 mai 21:18 OpenConcerto.h2.db
 -rw-r--r--   1 moi  moi  3945 19 mai 17:18 OpenConcerto.trace.db

 I launch the H2 console in embedded mode with the parameters:
 jdbc:h2:file:/Users/moi/Library/Application\ 
 Support/OpenConcerto/DBData/OpenConcerto;IFEXISTS=TRUE
 login and password

 The console seems to succesfully connect to the database (or else it 
 should display an error message, with the option IFEXISTS=TRUE), but: 
 Where are the tables ? Shouldn't there be the tables listed on the left 
 pane?
 What do I need to do to access these tables?
 Thanks


 https://lh3.googleusercontent.com/-oleaDCRp1cM/U3t30O5n70I/AD0/Ha6UpzVquKI/s1600/Capture+d%E2%80%99e%CC%81cran+2014-05-20+a%CC%80+00.21.00.png



-- 
You received this message because you are subscribed to the Google Groups H2 
Database group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to h2-database+unsubscr...@googlegroups.com.
To post to this group, send email to h2-database@googlegroups.com.
Visit this group at http://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.


[h2] Error in Meta data of ResultSet

2014-05-21 Thread christoff . schmitz
Hi,

in H2 1.3.173 the meta data for the ResultSet of query

SELECT 0.02

tells that the precision of the numeric column is 1 (but obviously it 
should be = 2 (scale)).

For

SELECT 1.02

the precision is returned as 3 (as expected). It seems to me that this is 
a bug for numeric literals in interval 

]-1, 1[

Can you tell me if this is already fixed for a later version of the 1.3 
branch?


Kind regards

Christoff Schmitz

F I N A R I S
Financial Software Partner GmbH
Sömmerringstrasse 23
60322 Frankfurt am Main

Fon:  +49 (0)69  / 254 98 - 24
Mobile: +49 (0)176 / 206 34 186
Fax:   +49 (0)69  / 254 98 - 50
eMail:mailto:christoff.schm...@finaris.de
www:  http://www.finaris.de und http://www.rapidrep.com


Disclaimer
The information contained in this e - mail and any attachments ( together 
the message) is intended for the addressee only and 
may contain confidential and/or privileged information. If you have 
received the message by mistake please delete it and notify 
the sender and do not copy or distribute it or disclose its contents to 
anyone.

FINARIS Financial Software Partner GmbH, Sömmerringstr. 23, 60322 
Frankfurt/Main, Germany
Registered at Frankfurt/Main, HRB 52873, Managing Directors: Dipl. Inf. 
Hermann Friebel, Dipl. Ing. Kai Bächle, Dipl. Inf. Werner Märkl


-- 
You received this message because you are subscribed to the Google Groups H2 
Database group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to h2-database+unsubscr...@googlegroups.com.
To post to this group, send email to h2-database@googlegroups.com.
Visit this group at http://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.


Re: [h2] Error in Meta data of ResultSet

2014-05-21 Thread Noel Grandin

Have you tried testing on the latest version?

On 2014-05-21 10:37, christoff.schm...@finaris.de wrote:


in H2 1.3.173 the meta data for the ResultSet of query



--
You received this message because you are subscribed to the Google Groups H2 
Database group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to h2-database+unsubscr...@googlegroups.com.
To post to this group, send email to h2-database@googlegroups.com.
Visit this group at http://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.


[h2] ArrayIndexOutOfBoundsException with union query

2014-05-21 Thread christoff . schmitz
Hi,

one of our customers is facing the following problem while using our 
product, which uses an embedded H2 database (v. 1.3.173).

The query looks like this:

SELECT INITIAL_FIXED_VOL, FIXED_YIELD_4AVG, FIXED_ORIGMAT_4AVG,
INITIAL_FLOAT_VOL, FLOAT_YIELD_4AVG, FLOAT_ORIGMAT_4AVG
FROM REPORT_0.KONTOKORRENT_FINAL_1
UNION
SELECT INITIAL_FIXED_VOL, FIXED_YIELD_4AVG, FIXED_ORIGMAT_4AVG,
INITIAL_FLOAT_VOL, FLOAT_YIELD_4AVG, FLOAT_ORIGMAT_4AVG
FROM REPORT_0.TERMINGELD_FINAL_1
UNION
SELECT INITIAL_FIXED_VOL, FIXED_YIELD_4AVG, FIXED_ORIGMAT_4AVG,
INITIAL_FLOAT_VOL, FLOAT_YIELD_4AVG, FLOAT_ORIGMAT_4AVG
FROM REPORT_0.REPOLEIHE_FINAL_1

The 3 objects in the from clauses are views that refer to a table 
function.

The following exception is thrown by H2 (full stack trace at the end of 
this email, it is quite complicated since the mentioned table functions 
execute code within the H2 database):

Caused by: java.lang.ArrayIndexOutOfBoundsException: 2048
  at org.h2.store.Data.writeVarLong(Data.java:1243)
  at org.h2.store.Data.writeValue(Data.java:577)
  at org.h2.store.Data.writeValue(Data.java:641)
  at org.h2.index.PageBtreeIndex.writeRow(PageBtreeIndex.java:387)
  at org.h2.index.PageBtreeLeaf.writeData(PageBtreeLeaf.java:292)
  at org.h2.index.PageBtreeLeaf.write(PageBtreeLeaf.java:266)
  at org.h2.store.PageStore.writeBack(PageStore.java:1015)
  at org.h2.util.CacheLRU.removeOld(CacheLRU.java:209)
  at org.h2.util.CacheLRU.removeOldIfRequired(CacheLRU.java:138)
  at org.h2.util.CacheLRU.put(CacheLRU.java:113)
  at org.h2.store.PageStore.getPage(PageStore.java:832)
  at org.h2.index.PageDataIndex.getPage(PageDataIndex.java:231)
  at org.h2.index.PageDataNode.getNextPage(PageDataNode.java:231)
  at org.h2.index.PageDataLeaf.getNextPage(PageDataLeaf.java:396)
  at org.h2.index.PageDataCursor.nextRow(PageDataCursor.java:93)
  at org.h2.index.PageDataCursor.next(PageDataCursor.java:52)
  at org.h2.index.IndexCursor.next(IndexCursor.java:271)
  at org.h2.table.TableFilter.next(TableFilter.java:359)
  at org.h2.command.dml.Select.queryFlat(Select.java:518)
  at org.h2.command.dml.Select.queryWithoutCache(Select.java:625)
  at org.h2.command.dml.Query.query(Query.java:314)
  at org.h2.command.dml.Query.query(Query.java:284)
  at org.h2.command.dml.Query.query(Query.java:36)
  at org.h2.command.CommandContainer.query(CommandContainer.java:91)
  at org.h2.command.Command.executeQuery(Command.java:195)
  ... 156 more

However, this problem does not occur, when UNION ALL is used instead of 
UNION. 
A workaround for my customer, but maybe you can extract useful 
information. 
Unfortunately, I cannot provide a simple reproduction code for this.



com.rapidrep.exception.SQLScriptletException: Allgemeiner Fehler:
java.lang.ArrayIndexOutOfBoundsException: 2048
General error: java.lang.ArrayIndexOutOfBoundsException: 2048; SQL
statement:


SELECT B.*, 'Y' AS SECURED,



( CASE
WHEN ((LIEFERUNG LIKE  'BCA_%' ) AND (1=1))

THEN  'OTHER'
ELSE NULL
END ) AS
KUNDENGRUPPE


,



( CASE
WHEN ((LIEFERUNG LIKE  'BCA_%' ) AND (1=1))
THEN  DATE '2013-12-31'
ELSE NULL
END ) AS
TRADE_DATE


,



( CASE
WHEN ((LIEFERUNG LIKE  'BCA_%' ) AND (1=1))
THEN  DATE '2014-01-31'
ELSE NULL
END ) AS
MATURITY_DATE


,



( CASE
WHEN ((LIEFERUNG LIKE  'BCA_%' ) AND (RIGHT( FINANZBESTANDSWAEHRUNG, 3) IN
('EUR', 'DEM', 'FFR', 'ITL')))

THEN  'EUR'
WHEN ((LIEFERUNG LIKE  'BCA_%' ) AND (1=1))

THEN   RIGHT( FINANZBESTANDSWAEHRUNG, 3)
ELSE NULL
END ) AS
CURRENCY


,



( CASE
WHEN ((LIEFERUNG LIKE  'BCA_%' ) AND (KONS_OHNE_R_V = 'nein'))

THEN  'J'
WHEN ((LIEFERUNG LIKE  'BCA_%' ) AND (1=1))

THEN  'N'
ELSE NULL
END ) AS
FG_EXTERN


,



( CASE
WHEN ((1=1) AND (1=1))

THEN  'FLOAT'
ELSE NULL
END ) AS
LEGTYPE


 FROM REPORT_0.KONTOKORRENT_1 B

 [5-173]
  at 
com.rapidrep.kernel.internaldb.common.tablefunctions.dataelement.DataElementTableFunctionManager.readTableFunction(DataElementTableFunctionManager.java:217)
  at 
com.rapidrep.kernel.internaldb.h2.tablefunctions.H2DataElementTableFunctionManager.readTableFunction(H2DataElementTableFunctionManager.java:98)
  at sun.reflect.GeneratedMethodAccessor54.invoke(Unknown Source)
  at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
  at java.lang.reflect.Method.invoke(Unknown Source)
  at 
org.h2.engine.FunctionAlias$JavaMethod.getValue(FunctionAlias.java:411)
  at org.h2.expression.JavaFunction.getValue(JavaFunction.java:39)
  at org.h2.table.FunctionTable.getValueResultSet(FunctionTable.java:209)
  at org.h2.table.FunctionTable.getResult(FunctionTable.java:180)
  at org.h2.index.FunctionIndex.find(FunctionIndex.java:50)
  at org.h2.index.BaseIndex.find(BaseIndex.java:126)
  at org.h2.index.IndexCursor.find(IndexCursor.java:155)
  at org.h2.table.TableFilter.next(TableFilter.java:328)
  at org.h2.command.dml.Select.queryFlat(Select.java:518)
  at org.h2.command.dml.Select.queryWithoutCache(Select.java:625)
  at org.h2.command.dml.Query.query(Query.java:314)
  at 

[h2] Re: Cannot connect to an existing embedded database

2014-05-21 Thread 'Ospeleo' via H2 Database
Hi,

The main problem is found. the '\ ' character in the path is not recognized.
I created a db in ~ and connected to it, create a table, disconnect.
I move the db in ~/Library and connect to it: the table is displayed.
I move the db in ~/Library/Application\ Support and connect to it: the 
table doesn't show.

Then, I move OpenConcerto.h2.db in ~/Library and connect to it.
Get the following error message
Unique index or primary key violation: PRIMARY KEY ON .PAGE_INDEX; 
SQL statement:
ALTER TABLE Default.FWK_MODULE_DEP ADD CONSTRAINT 
Default.FWK_MODULE_DEP_ID_MODULE_fkey FOREIGN KEY(ID_MODULE) REFERENCES 
Default.FWK_MODULE_METADATA(ID) ON DELETE CASCADE ON UPDATE CASCADE 
NOCHECK 
[23505-176]http://192.168.0.153:8082/login.do?jsessionid=77be6b1a68ea3468fb909c2871ce4302#
 23505/23505 

I'm investigating it and let you know
Thanks for the hints

Le mercredi 21 mai 2014 09:48:00 UTC+2, too a écrit :

 hi,
 Just few tips

- what error is in OpenConcerto.trace.db?
- try to create some table using the console. does that work? error?
- what happens if you move the DB to location without spaces?
- have you experimented with permissions to the DB file?

 Tono

 On Tuesday, May 20, 2014 5:47:15 PM UTC+2, Ospeleo wrote:

 Hi,
 What is wrong in my process ? 
 I need an outside view.
 I've been investigating this error for 12 hours over 3 days, thought it 
 was linked with my software which uses the H2 database (Openconcerto) but 
 it seems it is more H2/environment-related

 I use OSX10.6.8
 java version 1.6.0_65
 h2-1.3.176.jar

 I have a database (10mB) in 
 olivier:~ moi$ cd Library/Application\ Support/OpenConcerto/DBData/
 olivier:DBData moi$ ls -la
 total 19552
 drwxr-xr-x   4 moi  moi   136 19 mai 21:18 .
 drwxr-xr-x  24 moi  moi   816 19 mai 17:56 ..
 -rw-r--r--   1 moi  moi  10004480 19 mai 21:18 OpenConcerto.h2.db
 -rw-r--r--   1 moi  moi  3945 19 mai 17:18 OpenConcerto.trace.db

 I launch the H2 console in embedded mode with the parameters:
 jdbc:h2:file:/Users/moi/Library/Application\ 
 Support/OpenConcerto/DBData/OpenConcerto;IFEXISTS=TRUE
 login and password

 The console seems to succesfully connect to the database (or else it 
 should display an error message, with the option IFEXISTS=TRUE), but: 
 Where are the tables ? Shouldn't there be the tables listed on the left 
 pane?
 What do I need to do to access these tables?
 Thanks


 https://lh3.googleusercontent.com/-oleaDCRp1cM/U3t30O5n70I/AD0/Ha6UpzVquKI/s1600/Capture+d%E2%80%99e%CC%81cran+2014-05-20+a%CC%80+00.21.00.png



-- 
You received this message because you are subscribed to the Google Groups H2 
Database group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to h2-database+unsubscr...@googlegroups.com.
To post to this group, send email to h2-database@googlegroups.com.
Visit this group at http://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.


Re: [h2] Error in Meta data of ResultSet

2014-05-21 Thread christoff . schmitz
The result is the same for 1.3.176

Kind regards

Christoff Schmitz
F I N A R I S
Financial Software Partner GmbH
Sömmerringstrasse 23
60322 Frankfurt am Main
Fon:  +49 (0)69  / 254 98 - 24
Mobile: +49 (0)176 / 206 34 186
Fax:   +49 (0)69  / 254 98 - 50
eMail:mailto:christoff.schm...@finaris.de
www:  http://www.finaris.de und http://www.rapidrep.com 


-h2-database@googlegroups.com schrieb: - 
An: h2-database@googlegroups.com
Von: Noel Grandin 
Gesendet von: h2-database@googlegroups.com
Datum: 21.05.2014 10:38
Betreff: Re: [h2] Error in Meta data of ResultSet


Have you tried testing on the latest version?

On 2014-05-21 10:37, christoff.schm...@finaris.de wrote:

 in H2 1.3.173 the meta data for the ResultSet of query


-- 
You received this message because you are subscribed to the Google Groups H2 
Database group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to h2-database+unsubscr...@googlegroups.com.
To post to this group, send email to h2-database@googlegroups.com.
Visit this group at http://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.



Disclaimer
The information contained in this e - mail and any attachments ( together the 
message) is intended for the addressee only and 
may contain confidential and/or privileged information. If you have received 
the message by mistake please delete it and notify 
the sender and do not copy or distribute it or disclose its contents to anyone.

FINARIS Financial Software Partner GmbH, Sömmerringstr. 23, 60322 
Frankfurt/Main, Germany
Registered at Frankfurt/Main, HRB 52873, Managing Directors: Dipl. Inf. Hermann 
Friebel, Dipl. Ing. Kai Bächle, Dipl. Inf. Werner Märkl


-- 
You received this message because you are subscribed to the Google Groups H2 
Database group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to h2-database+unsubscr...@googlegroups.com.
To post to this group, send email to h2-database@googlegroups.com.
Visit this group at http://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.


Re: [h2] ArrayIndexOutOfBoundsException with union query

2014-05-21 Thread Noel Grandin

I have no idea what the underlying problem is.
But if you could create a standalone test case for it I could probably track it 
down.

In the meantime you could probably work around it by bumping up your cache size.
Append something like this to your URL
   ;CACHE_SIZE=1024
where the size is in kilobytes.

On 2014-05-21 10:42, christoff.schm...@finaris.de wrote:


one of our customers is facing the following problem while using our product, 
which uses an embedded H2 database (v.
1.3.173).



--
You received this message because you are subscribed to the Google Groups H2 
Database group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to h2-database+unsubscr...@googlegroups.com.
To post to this group, send email to h2-database@googlegroups.com.
Visit this group at http://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.


[h2] Re: Cannot connect to an existing embedded database

2014-05-21 Thread 'Ospeleo' via H2 Database


Le mercredi 21 mai 2014 10:55:55 UTC+2, Ospeleo a écrit :

 Hi,

 The main problem is found. the '\ ' character in the path is not 
 recognized.
 I created a db in ~ and connected to it, create a table, disconnect.
 I move the db in ~/Library and connect to it: the table is displayed.
 I move the db in ~/Library/Application\ Support and connect to it: the 
 table doesn't show.

 Then, I move OpenConcerto.h2.db in ~/Library and connect to it.
 Get the following error message
 Unique index or primary key violation: PRIMARY KEY ON .PAGE_INDEX; 
 SQL statement:
 ALTER TABLE Default.FWK_MODULE_DEP ADD CONSTRAINT 
 Default.FWK_MODULE_DEP_ID_MODULE_fkey FOREIGN KEY(ID_MODULE) REFERENCES 
 Default.FWK_MODULE_METADATA(ID) ON DELETE CASCADE ON UPDATE CASCADE 
 NOCHECK 
 [23505-176]http://192.168.0.153:8082/login.do?jsessionid=77be6b1a68ea3468fb909c2871ce4302#
  23505/23505 

 I'm investigating it and let you know
 Thanks for the hints

 Le mercredi 21 mai 2014 09:48:00 UTC+2, too a écrit :

 hi,
 Just few tips

- what error is in OpenConcerto.trace.db?
- try to create some table using the console. does that work? error?
- what happens if you move the DB to location without spaces?
- have you experimented with permissions to the DB file?

 Tono

 On Tuesday, May 20, 2014 5:47:15 PM UTC+2, Ospeleo wrote:

 Hi,
 What is wrong in my process ? 
 I need an outside view.
 I've been investigating this error for 12 hours over 3 days, thought it 
 was linked with my software which uses the H2 database (Openconcerto) but 
 it seems it is more H2/environment-related

 I use OSX10.6.8
 java version 1.6.0_65
 h2-1.3.176.jar

 I have a database (10mB) in 
 olivier:~ moi$ cd Library/Application\ Support/OpenConcerto/DBData/
 olivier:DBData moi$ ls -la
 total 19552
 drwxr-xr-x   4 moi  moi   136 19 mai 21:18 .
 drwxr-xr-x  24 moi  moi   816 19 mai 17:56 ..
 -rw-r--r--   1 moi  moi  10004480 19 mai 21:18 OpenConcerto.h2.db
 -rw-r--r--   1 moi  moi  3945 19 mai 17:18 OpenConcerto.trace.db

 I launch the H2 console in embedded mode with the parameters:
 jdbc:h2:file:/Users/moi/Library/Application\ 
 Support/OpenConcerto/DBData/OpenConcerto;IFEXISTS=TRUE
 login and password

 The console seems to succesfully connect to the database (or else it 
 should display an error message, with the option IFEXISTS=TRUE), but: 
 Where are the tables ? Shouldn't there be the tables listed on the left 
 pane?
 What do I need to do to access these tables?
 Thanks


 https://lh3.googleusercontent.com/-oleaDCRp1cM/U3t30O5n70I/AD0/Ha6UpzVquKI/s1600/Capture+d%E2%80%99e%CC%81cran+2014-05-20+a%CC%80+00.21.00.png



-- 
You received this message because you are subscribed to the Google Groups H2 
Database group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to h2-database+unsubscr...@googlegroups.com.
To post to this group, send email to h2-database@googlegroups.com.
Visit this group at http://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.


Re: [h2] Error in Meta data of ResultSet

2014-05-21 Thread Noel Grandin



On 2014-05-21 10:37, christoff.schm...@finaris.de wrote:


*SELECT**0.02*

tells that the precision of the numeric column is 1 (but obviously it should be 
= 2 (scale)).



No, the precision is the number of significant digits in a number.
In this case the precision is 1 since there is only one significant digit in 
the number.

--
You received this message because you are subscribed to the Google Groups H2 
Database group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to h2-database+unsubscr...@googlegroups.com.
To post to this group, send email to h2-database@googlegroups.com.
Visit this group at http://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.


Re: [h2] Row not found when trying to delete from index [v1.3.174]

2014-05-21 Thread Sander Sõnajalg
Hi,

so this is basically a known issue? And as I understand from your context,
you are currently lacking a test case that would reproduce the issue? I
can't provide one at the moment either, as I can't acquire the customer's
database that reproduces this (and it doesn't occur in our own
environment). But sooner or later I might also be able to get a database
instance that is affected by this.. should I then convert it into a ticket
and provide a test case?

Anyhow, maybe you have some recommendations about what to try to resolve
this..? Dropping and recreating the index probably doesn't provide a final
solution, as i read from other threads.

Thanks!
Sander.





 I'm afraid MVCC is still experimental in that release. It works for
 some people, but not for everybody.

 I know this is no help, but regarding the experimental options, I have
 seen



-- 
You received this message because you are subscribed to the Google Groups H2 
Database group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to h2-database+unsubscr...@googlegroups.com.
To post to this group, send email to h2-database@googlegroups.com.
Visit this group at http://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.


[h2] Re: Cannot connect to an existing embedded database

2014-05-21 Thread too
I have not realized this right away but backward slash is not URI 
replacement for space. it is %20 . The slash is usually used in file paths 
but not in the URI. JDBC connection string is URI hence you need to make 
sure it is valid. Try the %20 perhaps that will work for you. Maybe 
malformed URI caused driver to ignore IFEXISTS and your blank DB got 
created somewhere. try searching the drive or subpaths of your path or by 
filename

Tono

On Wednesday, May 21, 2014 10:55:55 AM UTC+2, Ospeleo wrote:

 Hi,

 The main problem is found. the '\ ' character in the path is not 
 recognized.
 I created a db in ~ and connected to it, create a table, disconnect.
 I move the db in ~/Library and connect to it: the table is displayed.
 I move the db in ~/Library/Application\ Support and connect to it: the 
 table doesn't show.

 Then, I move OpenConcerto.h2.db in ~/Library and connect to it.
 Get the following error message
 Unique index or primary key violation: PRIMARY KEY ON .PAGE_INDEX; 
 SQL statement:
 ALTER TABLE Default.FWK_MODULE_DEP ADD CONSTRAINT 
 Default.FWK_MODULE_DEP_ID_MODULE_fkey FOREIGN KEY(ID_MODULE) REFERENCES 
 Default.FWK_MODULE_METADATA(ID) ON DELETE CASCADE ON UPDATE CASCADE 
 NOCHECK 
 [23505-176]http://192.168.0.153:8082/login.do?jsessionid=77be6b1a68ea3468fb909c2871ce4302#
  23505/23505 

 I'm investigating it and let you know
 Thanks for the hints

 Le mercredi 21 mai 2014 09:48:00 UTC+2, too a écrit :

 hi,
 Just few tips

- what error is in OpenConcerto.trace.db?
- try to create some table using the console. does that work? error?
- what happens if you move the DB to location without spaces?
- have you experimented with permissions to the DB file?

 Tono

 On Tuesday, May 20, 2014 5:47:15 PM UTC+2, Ospeleo wrote:

 Hi,
 What is wrong in my process ? 
 I need an outside view.
 I've been investigating this error for 12 hours over 3 days, thought it 
 was linked with my software which uses the H2 database (Openconcerto) but 
 it seems it is more H2/environment-related

 I use OSX10.6.8
 java version 1.6.0_65
 h2-1.3.176.jar

 I have a database (10mB) in 
 olivier:~ moi$ cd Library/Application\ Support/OpenConcerto/DBData/
 olivier:DBData moi$ ls -la
 total 19552
 drwxr-xr-x   4 moi  moi   136 19 mai 21:18 .
 drwxr-xr-x  24 moi  moi   816 19 mai 17:56 ..
 -rw-r--r--   1 moi  moi  10004480 19 mai 21:18 OpenConcerto.h2.db
 -rw-r--r--   1 moi  moi  3945 19 mai 17:18 OpenConcerto.trace.db

 I launch the H2 console in embedded mode with the parameters:
 jdbc:h2:file:/Users/moi/Library/Application\ 
 Support/OpenConcerto/DBData/OpenConcerto;IFEXISTS=TRUE
 login and password

 The console seems to succesfully connect to the database (or else it 
 should display an error message, with the option IFEXISTS=TRUE), but: 
 Where are the tables ? Shouldn't there be the tables listed on the left 
 pane?
 What do I need to do to access these tables?
 Thanks


 https://lh3.googleusercontent.com/-oleaDCRp1cM/U3t30O5n70I/AD0/Ha6UpzVquKI/s1600/Capture+d%E2%80%99e%CC%81cran+2014-05-20+a%CC%80+00.21.00.png



-- 
You received this message because you are subscribed to the Google Groups H2 
Database group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to h2-database+unsubscr...@googlegroups.com.
To post to this group, send email to h2-database@googlegroups.com.
Visit this group at http://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.


[h2] Re: Cannot connect to an existing embedded database

2014-05-21 Thread 'Ospeleo' via H2 Database
I have the same blank database If I use %20 or '\ '

But when I move the database (temporarily) to another location, without a 
space in the path, I get the error message cited below

Le mercredi 21 mai 2014 13:44:01 UTC+2, too a écrit :

 I have not realized this right away but backward slash is not URI 
 replacement for space. it is %20 . The slash is usually used in file paths 
 but not in the URI. JDBC connection string is URI hence you need to make 
 sure it is valid. Try the %20 perhaps that will work for you. Maybe 
 malformed URI caused driver to ignore IFEXISTS and your blank DB got 
 created somewhere. try searching the drive or subpaths of your path or by 
 filename

 Tono

 On Wednesday, May 21, 2014 10:55:55 AM UTC+2, Ospeleo wrote:

 Hi,

 The main problem is found. the '\ ' character in the path is not 
 recognized.
 I created a db in ~ and connected to it, create a table, disconnect.
 I move the db in ~/Library and connect to it: the table is displayed.
 I move the db in ~/Library/Application\ Support and connect to it: the 
 table doesn't show.

 Then, I move OpenConcerto.h2.db in ~/Library and connect to it.
 Get the following error message
 Unique index or primary key violation: PRIMARY KEY ON .PAGE_INDEX; 
 SQL statement:
 ALTER TABLE Default.FWK_MODULE_DEP ADD CONSTRAINT 
 Default.FWK_MODULE_DEP_ID_MODULE_fkey FOREIGN KEY(ID_MODULE) REFERENCES 
 Default.FWK_MODULE_METADATA(ID) ON DELETE CASCADE ON UPDATE CASCADE 
 NOCHECK 
 [23505-176]http://192.168.0.153:8082/login.do?jsessionid=77be6b1a68ea3468fb909c2871ce4302#
  23505/23505 

 I'm investigating it and let you know
 Thanks for the hints

 Le mercredi 21 mai 2014 09:48:00 UTC+2, too a écrit :

 hi,
 Just few tips

- what error is in OpenConcerto.trace.db?
- try to create some table using the console. does that work? error?
- what happens if you move the DB to location without spaces?
- have you experimented with permissions to the DB file?

 Tono

 On Tuesday, May 20, 2014 5:47:15 PM UTC+2, Ospeleo wrote:

 Hi,
 What is wrong in my process ? 
 I need an outside view.
 I've been investigating this error for 12 hours over 3 days, thought it 
 was linked with my software which uses the H2 database (Openconcerto) but 
 it seems it is more H2/environment-related

 I use OSX10.6.8
 java version 1.6.0_65
 h2-1.3.176.jar

 I have a database (10mB) in 
 olivier:~ moi$ cd Library/Application\ Support/OpenConcerto/DBData/
 olivier:DBData moi$ ls -la
 total 19552
 drwxr-xr-x   4 moi  moi   136 19 mai 21:18 .
 drwxr-xr-x  24 moi  moi   816 19 mai 17:56 ..
 -rw-r--r--   1 moi  moi  10004480 19 mai 21:18 OpenConcerto.h2.db
 -rw-r--r--   1 moi  moi  3945 19 mai 17:18 OpenConcerto.trace.db

 I launch the H2 console in embedded mode with the parameters:
 jdbc:h2:file:/Users/moi/Library/Application\ 
 Support/OpenConcerto/DBData/OpenConcerto;IFEXISTS=TRUE
 login and password

 The console seems to succesfully connect to the database (or else it 
 should display an error message, with the option IFEXISTS=TRUE), but: 
 Where are the tables ? Shouldn't there be the tables listed on the left 
 pane?
 What do I need to do to access these tables?
 Thanks


 https://lh3.googleusercontent.com/-oleaDCRp1cM/U3t30O5n70I/AD0/Ha6UpzVquKI/s1600/Capture+d%E2%80%99e%CC%81cran+2014-05-20+a%CC%80+00.21.00.png



-- 
You received this message because you are subscribed to the Google Groups H2 
Database group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to h2-database+unsubscr...@googlegroups.com.
To post to this group, send email to h2-database@googlegroups.com.
Visit this group at http://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.


[h2] Error when opening the database a second time

2014-05-21 Thread Benoit HELIE
I'm using H2 console to open a database. 
When opening the first time the database, I'm able to see the different 
tables of the database and execute SQL scripts.

When I try to open it a second time, I always have the following error :

Unique index or primary key violation: PRIMARY KEY ON .PAGE_INDEX; 
SQL statement:
ALTER TABLE PUBLIC.CORE_GROUP_MEMBER ADD CONSTRAINT 
PUBLIC.FK_GROUP_MEMBER_PARTY FOREIGN KEY(PARTY_ID) REFERENCES 
PUBLIC.CORE_PARTY(PARTY_ID) NOCHECK [23505-176] 23505/23505 (Help)
org.h2.jdbc.JdbcSQLException: Unique index or primary key violation: 
PRIMARY KEY ON .PAGE_INDEX; SQL statement:
ALTER TABLE PUBLIC.CORE_GROUP_MEMBER ADD CONSTRAINT 
PUBLIC.FK_GROUP_MEMBER_PARTY FOREIGN KEY(PARTY_ID) REFERENCES 
PUBLIC.CORE_PARTY(PARTY_ID) NOCHECK [23505-176]
 at 
org.h2.message.DbException.getJdbcSQLException(DbException.java:344) 
at org.h2.message.DbException.get(DbException.java:178) 
at org.h2.message.DbException.get(DbException.java:154) 
at 
org.h2.index.PageDataIndex.getNewDuplicateKeyException(PageDataIndex.java:166)
 at org.h2.index.PageDataIndex.add(PageDataIndex.java:144) 
at org.h2.store.PageStore.addMeta(PageStore.java:1808) 
at org.h2.index.PageBtreeIndex.init(PageBtreeIndex.java:64) 
at org.h2.table.RegularTable.addIndex(RegularTable.java:235) 
at 
org.h2.command.ddl.AlterTableAddConstraint.createIndex(AlterTableAddConstraint.java:280)
 at 
org.h2.command.ddl.AlterTableAddConstraint.tryUpdate(AlterTableAddConstraint.java:205)
 at 
org.h2.command.ddl.AlterTableAddConstraint.update(AlterTableAddConstraint.java:73)
 at org.h2.engine.MetaRecord.execute(MetaRecord.java:59) 
at org.h2.engine.Database.open(Database.java:719) 
at org.h2.engine.Database.openDatabase(Database.java:260) 
at org.h2.engine.Database.init(Database.java:254) 
at org.h2.engine.Engine.openSession(Engine.java:57) 
at org.h2.engine.Engine.openSession(Engine.java:164) 
at org.h2.engine.Engine.createSessionAndValidate(Engine.java:142) 
at org.h2.engine.Engine.createSession(Engine.java:125) 
at org.h2.engine.Engine.createSession(Engine.java:27) 
at 
org.h2.engine.SessionRemote.connectEmbeddedOrServer(SessionRemote.java:331)
 at org.h2.jdbc.JdbcConnection.init(JdbcConnection.java:107) 
at org.h2.jdbc.JdbcConnection.init(JdbcConnection.java:91) 
at org.h2.Driver.connect(Driver.java:74) 
at org.h2.server.web.WebServer.getConnection(WebServer.java:684) 
at org.h2.server.web.WebApp.login(WebApp.java:958) 
at org.h2.server.web.WebApp.process(WebApp.java:212) 
at org.h2.server.web.WebApp.processRequest(WebApp.java:171) 
at org.h2.server.web.WebThread.process(WebThread.java:138) 
at org.h2.server.web.WebThread.run(WebThread.java:94) 
at java.lang.Thread.run(Unknown Source) 

The database is used for a test management tool which I want to update.
Anyone could help ?

Best regards

-- 
You received this message because you are subscribed to the Google Groups H2 
Database group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to h2-database+unsubscr...@googlegroups.com.
To post to this group, send email to h2-database@googlegroups.com.
Visit this group at http://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.


[h2] Re: Error when opening the database a second time

2014-05-21 Thread 'Ospeleo' via H2 Database
hi, 
it is the same error message I have reported on this subject, posted today: 
https://groups.google.com/d/msg/h2-database/iPAECUAML4Y/70PkSslWInQJ

I access my database via my application/ Works great. I want to manipulate 
the table. The same error than yours.


Le mercredi 21 mai 2014 14:30:57 UTC+2, Benoit HELIE a écrit :

 I'm using H2 console to open a database. 
 When opening the first time the database, I'm able to see the different 
 tables of the database and execute SQL scripts.

 When I try to open it a second time, I always have the following error :

 Unique index or primary key violation: PRIMARY KEY ON .PAGE_INDEX; 
 SQL statement:
 ALTER TABLE PUBLIC.CORE_GROUP_MEMBER ADD CONSTRAINT 
 PUBLIC.FK_GROUP_MEMBER_PARTY FOREIGN KEY(PARTY_ID) REFERENCES 
 PUBLIC.CORE_PARTY(PARTY_ID) NOCHECK [23505-176] 23505/23505 (Help)
 org.h2.jdbc.JdbcSQLException: Unique index or primary key violation: 
 PRIMARY KEY ON .PAGE_INDEX; SQL statement:
 ALTER TABLE PUBLIC.CORE_GROUP_MEMBER ADD CONSTRAINT 
 PUBLIC.FK_GROUP_MEMBER_PARTY FOREIGN KEY(PARTY_ID) REFERENCES 
 PUBLIC.CORE_PARTY(PARTY_ID) NOCHECK [23505-176]
  at 
 org.h2.message.DbException.getJdbcSQLException(DbException.java:344) 
 at org.h2.message.DbException.get(DbException.java:178) 
 at org.h2.message.DbException.get(DbException.java:154) 
 at 
 org.h2.index.PageDataIndex.getNewDuplicateKeyException(PageDataIndex.java:166)
  at org.h2.index.PageDataIndex.add(PageDataIndex.java:144) 
 at org.h2.store.PageStore.addMeta(PageStore.java:1808) 
 at org.h2.index.PageBtreeIndex.init(PageBtreeIndex.java:64) 
 at org.h2.table.RegularTable.addIndex(RegularTable.java:235) 
 at 
 org.h2.command.ddl.AlterTableAddConstraint.createIndex(AlterTableAddConstraint.java:280)
  at 
 org.h2.command.ddl.AlterTableAddConstraint.tryUpdate(AlterTableAddConstraint.java:205)
  at 
 org.h2.command.ddl.AlterTableAddConstraint.update(AlterTableAddConstraint.java:73)
  at org.h2.engine.MetaRecord.execute(MetaRecord.java:59) 
 at org.h2.engine.Database.open(Database.java:719) 
 at org.h2.engine.Database.openDatabase(Database.java:260) 
 at org.h2.engine.Database.init(Database.java:254) 
 at org.h2.engine.Engine.openSession(Engine.java:57) 
 at org.h2.engine.Engine.openSession(Engine.java:164) 
 at org.h2.engine.Engine.createSessionAndValidate(Engine.java:142) 
 at org.h2.engine.Engine.createSession(Engine.java:125) 
 at org.h2.engine.Engine.createSession(Engine.java:27) 
 at 
 org.h2.engine.SessionRemote.connectEmbeddedOrServer(SessionRemote.java:331)
  at org.h2.jdbc.JdbcConnection.init(JdbcConnection.java:107) 
 at org.h2.jdbc.JdbcConnection.init(JdbcConnection.java:91) 
 at org.h2.Driver.connect(Driver.java:74) 
 at org.h2.server.web.WebServer.getConnection(WebServer.java:684) 
 at org.h2.server.web.WebApp.login(WebApp.java:958) 
 at org.h2.server.web.WebApp.process(WebApp.java:212) 
 at org.h2.server.web.WebApp.processRequest(WebApp.java:171) 
 at org.h2.server.web.WebThread.process(WebThread.java:138) 
 at org.h2.server.web.WebThread.run(WebThread.java:94) 
 at java.lang.Thread.run(Unknown Source) 

 The database is used for a test management tool which I want to update.
 Anyone could help ?

 Best regards


-- 
You received this message because you are subscribed to the Google Groups H2 
Database group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to h2-database+unsubscr...@googlegroups.com.
To post to this group, send email to h2-database@googlegroups.com.
Visit this group at http://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.


Re: [h2] Unique index or primary key violation: SYS_ID ON PUBLIC.SYS(ID) [23505-168] (using 1.3.168)

2014-05-21 Thread jack jin
when I upgrade to 1.3.176,I have the same problem.  the old version h2 is 
works fine with the db file

On Tuesday, May 6, 2014 5:00:52 PM UTC+8, Germano Rizzo wrote:

 Hi Thomas,
 so your opinion is that all the db's are corrupted? The strange 
 thing is, they fail to open only with the latest stable version. Every 
 other version I tried works fine, and this configuration have worked in 40 
 installations for 3 years now, across different versions of H2. Do you want 
 me to start another thread?

  Germano

 Il giorno martedì 6 maggio 2014 07:59:45 UTC+2, Thomas Mueller ha scritto:

 Hi,

 If you are using LOCK_MODE=0;UNDO_LOG=0 then you need to be aware of the 
 risks. See the FAQ and the documentation.

 Please use different email subjects for different problems.

 Regards,
 Thomas


 On Monday, May 5, 2014, mano german...@gmail.com wrote:

 mano wrote
  Opening it with version 1.3.168 will give the error.

 Sorry, I meant 1.3.176.




 --
 View this message in context: 
 http://h2-database.66688.n3.nabble.com/Unique-index-or-primary-key-violation-SYS-ID-ON-PUBLIC-SYS-ID-23505-168-using-1-3-168-tp4028700p4029078.html
 Sent from the H2 Database mailing list archive at Nabble.com.

 --
 You received this message because you are subscribed to the Google 
 Groups H2 Database group.
 To unsubscribe from this group and stop receiving emails from it, send 
 an email to h2-database+unsubscr...@googlegroups.com.
 To post to this group, send email to h2-database@googlegroups.com.
 Visit this group at http://groups.google.com/group/h2-database.
 For more options, visit https://groups.google.com/d/optout.

 

-- 
You received this message because you are subscribed to the Google Groups H2 
Database group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to h2-database+unsubscr...@googlegroups.com.
To post to this group, send email to h2-database@googlegroups.com.
Visit this group at http://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.