sagarswathi / h2database

Automatically exported from code.google.com/p/h2database
0 stars 1 forks source link

when execute select statement it return java.lang.arrayIndexoutofboundsexception #428

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. I am using h2 console to do a select statement on my table.
2.
3.

What is the expected output? What do you see instead?
org.h2.jdbc.JdbcSQLException: General error: 
"java.lang.ArrayIndexOutOfBoundsException: -1"; SQL statement:
SELECT * FROM NOTIFY_ACTIVE [50000-169]
    at org.h2.message.DbException.getJdbcSQLException(DbException.java:329)
    at org.h2.message.DbException.get(DbException.java:158)
    at org.h2.message.DbException.convert(DbException.java:281)
    at org.h2.command.Command.executeQuery(Command.java:195)
    at org.h2.jdbc.JdbcStatement.executeInternal(JdbcStatement.java:173)
    at org.h2.jdbc.JdbcStatement.execute(JdbcStatement.java:152)
    at org.h2.server.web.WebApp.getResult(WebApp.java:1311)
    at org.h2.server.web.WebApp.query(WebApp.java:1001)
    at org.h2.server.web.WebApp$1.next(WebApp.java:964)
    at org.h2.server.web.WebApp$1.next(WebApp.java:953)
    at org.h2.server.web.WebThread.process(WebThread.java:166)
    at org.h2.server.web.WebThread.run(WebThread.java:93)
    at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.ArrayIndexOutOfBoundsException: -1
    at org.h2.index.PageDataLeaf.getNextPage(PageDataLeaf.java:392)
    at org.h2.index.PageDataCursor.nextRow(PageDataCursor.java:90)
    at org.h2.index.PageDataCursor.next(PageDataCursor.java:49)
    at org.h2.index.IndexCursor.next(IndexCursor.java:238)
    at org.h2.table.TableFilter.next(TableFilter.java:353)
    at org.h2.command.dml.Select.queryFlat(Select.java:513)
    at org.h2.command.dml.Select.queryWithoutCache(Select.java:618)
    at org.h2.command.dml.Query.query(Query.java:307)
    at org.h2.command.dml.Query.query(Query.java:277)
    at org.h2.command.dml.Query.query(Query.java:36)
    at org.h2.command.CommandContainer.query(CommandContainer.java:86)
    at org.h2.command.Command.executeQuery(Command.java:191)
    ... 9 more

Please use labels and text to provide additional information.

Original issue reported on code.google.com by zhouchi....@gmail.com on 30 Nov 2012 at 2:30

GoogleCodeExporter commented 8 years ago
- What is your database URL?
- Did you use LOG=0 or LOG=1? Did you read the FAQ about it?
- Did the system ever run out of disk space?
- Could you send the full stack trace of the exception including message text?
- Did you use SHUTDOWN DEFRAG or the database setting DEFRAG_ALWAYS with H2 
version 1.3.159 or older?
- How many connections does your application use concurrently?
- Do you use temporary tables?
- With which version of H2 was this database created?
    You can find it out using:
    select * from information_schema.settings where name='CREATE_BUILD'
    or have a look in the SQL script created by the recover tool.
- Did the application run out of memory (once, or multiple times)?
- Do you use any settings or special features (for example cache settings,
    two phase commit, linked tables)?
- Do you use any H2-specific system properties?
- Is the application multi-threaded?
- What operating system, file system, and virtual machine
    (java -version) do you use?
- How did you start the Java process (java -Xmx... and so on)?
- Is it (or was it at some point) a networked file system?
- How big is the database (file sizes)?
- How much heap memory does the Java process have?
- Is the database usually closed normally, or is process terminated
    forcefully or the computer switched off?
- Is it possible to reproduce this problem using a fresh database
    (sometimes, or always)?
- Are there any other exceptions (maybe in the .trace.db file)?
    Could you send them please?
- Do you still have any .trace.db files, and if yes could you send them?
- Could you send the .h2.db file where this exception occurs?

Original comment by thomas.t...@gmail.com on 30 Nov 2012 at 6:54