First Query Always Takes More Time Than Subsequent Queries Executed Within The Same Connection in JDBC
Last updated on MARCH 08, 2017
Applies to:JDBC - Version 22.214.171.124 and later
Information in this document applies to any platform.
The first query, no matter its complexity (even select 1 from dual), seems to incur an additional ~300ms penalty.
select 1 from dual; <-- slow
complex query <-- fast
Second run with different order of queries:
complex query <-- slow
select 1 from dual <-- fast
Why is this behavior?
Sign In with your My Oracle Support account
Don't have a My Oracle Support account? Click to get started
My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms