Exception when running ConvertTraceFile

36 views
Skip to first unread message

WHänsch

unread,
Mar 27, 2012, 8:05:24 AM3/27/12
to h2-da...@googlegroups.com
Hello

C:\Program Files (x86)\H2\bin>java -cp h2.jar org.h2.tools.ConvertTraceFile -traceFile "c:\h2\aura.trace.db" -script "c:\h2\trace.sql"
Exception in thread "main" java.lang.NumberFormatException: For input string: "1332846741070"
        at java.lang.NumberFormatException.forInputString(Unknown Source)
        at java.lang.Integer.parseInt(Unknown Source)
        at java.lang.Integer.parseInt(Unknown Source)
        at org.h2.tools.ConvertTraceFile.convertFile(ConvertTraceFile.java:159)
        at org.h2.tools.ConvertTraceFile.runTool(ConvertTraceFile.java:99)
        at org.h2.tools.ConvertTraceFile.main(ConvertTraceFile.java:76)

This are the first 3 lines from the trace file:
03-27 13:45:13 jdbc[2]:
/*SQL t:1332848713975*/SET TRACE_LEVEL_FILE 2;
03-27 13:45:13 command: slow query: 1,332,848,713,975 ms

Version: H2 1.3.159 (2011-08-13)


Any idea?
Thanks in advance.

Regards
Wolfgang

Noel Grandin

unread,
Mar 27, 2012, 8:14:48 AM3/27/12
to h2-da...@googlegroups.com, WHänsch
Wow, that is a seriously long running query :-)

Thanks, that is a bug, fix committed to SVN.

> --
> You received this message because you are subscribed to the Google
> Groups "H2 Database" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/h2-database/-/0gczm0wmZisJ.
> To post to this group, send email to h2-da...@googlegroups.com.
> To unsubscribe from this group, send email to
> h2-database...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/h2-database?hl=en.

Thomas Mueller

unread,
Mar 28, 2012, 1:16:59 PM3/28/12
to h2-da...@googlegroups.com
Hi,

Was it really such a long running query, or was the system date or
time changed while running it?

(probably the System.currentTimeMillis() needs to be replaced with
System.nanoTime())

Regards,
Thomas


On Tue, Mar 27, 2012 at 2:14 PM, Noel Grandin <noelg...@gmail.com> wrote:
> Wow, that is a seriously long running query :-)
>
> Thanks, that is a bug, fix committed to SVN.
>
>

Hänsch, Wolfgang

unread,
Mar 29, 2012, 9:35:09 AM3/29/12
to h2-da...@googlegroups.com
Hi,
There was no date or time change.
I assume the trace output is wrong.

03-27 13:45:13 jdbc[2]:
/*SQL t:1332848713975*/SET TRACE_LEVEL_FILE 2;

^^^^^^^^^^^^^


03-27 13:45:13 command: slow query: 1,332,848,713,975 ms

After ConvertTraceFile the SQL Statement Statistics is useless.
SET TRACE_LEVEL_FILE shows 100%

Regards
Wolfgang

Thomas Mueller

unread,
Mar 29, 2012, 2:34:38 PM3/29/12
to h2-da...@googlegroups.com
Hi,

It looks like a bug, I need to investigate. As a workaround, it seems
you could remove this line from the .trace.db file and run the
ConvertTraceFile tool again.

Regards,
Thomas

2012/3/29 Hänsch, Wolfgang <wolfgang...@ts.fujitsu.com>:

Thomas Mueller

unread,
Apr 25, 2012, 2:58:53 PM4/25/12
to h2-da...@googlegroups.com
Hi,

I found out this is a bug. It will be fixed in the next release.

Regards,
Thomas
Reply all
Reply to author
Forward
0 new messages