Hello, 

I tried this in new H2 1.4.197 and the result is the same. I do not see any 
command from file running by RUNSCRIPT command in QUERY_STATISTICS table. 

Please, any hint how to measure SQL commands from external SQL file 
executed by RUNSCRIPT is highly welcome by me. 

Regards, Stepan 

Dne úterý 5. prosince 2017 13:33:27 UTC t603 napsal(a):
>
> Hello, 
>
> I am facing strange behavior of QUERY_STATISTICS in RUNSCRIPT. It is 
> ignored or I do not know how to set it properly. 
>
> See my test case in H2 1.4.196 InMemory: 
>
> --this is the file c:\temp\temp\test.sql: 
> set QUERY_STATISTICS false; 
> set QUERY_STATISTICS true; 
> set QUERY_STATISTICS_MAX_ENTRIES 1000; 
> select current_timestamp; 
> select 'test'; 
> drop table if exists LOG; 
> create table LOG as select * from "INFORMATION_SCHEMA"."QUERY_STATISTICS"; 
> insert into LOG (SQL_STATEMENT) values('manual test entry'); 
> select * from LOG; 
>
> then c:\temp\temp\test.sql is called as: 
>
> runscript from 'c:\temp\temp\test.sql'; 
> select * from LOG; 
> --no QUERY_STATISTICS is displayed, only "manual test entry" record 
>
> Can I ask You, how to get QUERY_STATISTICS from SQL called from RUNSCRIPT? 
> I have quite complex of parametrised SQL commands and I can not have all of 
> these command in one big command. 
>
> When I run set of SQL commands from 'c:\temp\temp\test.sql', it works OK. 
>
> Regards, Stepan 
>
>
>

-- 
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 [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.

Reply via email to