473,385 Members | 1,782 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

estimated execution plan

Hi NG,

does IBM Universal Database 8.2 make any difference between actual and
estimated execution plans like in SQL Server ("set showplan_all on" for
estimated execution plan and "set statistics profile on" for actual
execution plan)? Does "explain plan selection for" generate the *estimated*
execution plan? Didn't find any distinction of actual or estimated execution
plans in the information center.

Thanks for help,
Ina
Feb 26 '06 #1
2 3701
"Ina Schmitz" <we*@inalein.net> wrote in message
news:dt*************@news.t-online.com...
Hi NG,

does IBM Universal Database 8.2 make any difference between actual and
estimated execution plans like in SQL Server ("set showplan_all on" for
estimated execution plan and "set statistics profile on" for actual
execution plan)? Does "explain plan selection for" generate the
*estimated* execution plan? Didn't find any distinction of actual or
estimated execution plans in the information center.

Thanks for help,
Ina


The explain should show you the actual execution plan if the dynamic SQL was
submitted at that same point in time, assuming that the optimization level
is the same for the explain and the client that runs the SQL.

If the SQL statement is statically bound, then the execution plan was
created at bind time and will not change unless a rebind is performed.
Feb 27 '06 #2
Mark A wrote:
"Ina Schmitz" <we*@inalein.net> wrote in message
news:dt*************@news.t-online.com...
Hi NG,

does IBM Universal Database 8.2 make any difference between actual and
estimated execution plans like in SQL Server ("set showplan_all on" for
estimated execution plan and "set statistics profile on" for actual
execution plan)? Does "explain plan selection for" generate the
*estimated* execution plan? Didn't find any distinction of actual or
estimated execution plans in the information center.
The explain should show you the actual execution plan if the dynamic SQL
was submitted at that same point in time, assuming that the optimization
level is the same for the explain and the client that runs the SQL.


In short: DB2 does have only one plan for a SQL statement: the actual one.
There is no mechanism to come up with an "estimated plan".
If the SQL statement is statically bound, then the execution plan was
created at bind time and will not change unless a rebind is performed.


And for dynamic SQL DB2 will take the execution plan from the statement
cache if it is still there (that's why you should flush that cache after
the statistics are collected).

--
Knut Stolze
DB2 Information Integration Development
IBM Germany
Feb 27 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Dan | last post by:
I am new to tuning and I am having some trouble with my Oracle 9.2.0.1. I have a database that I am trying to gain consistent performance out of but I seem to have changing execution plans. Due...
2
by: T Chaudhary | last post by:
Hi, I have a question about estimated query execution plans that are generated in QA of MSSQL. If I point at an icon/physical operator in the estimated QEP, it shows me some statistics about...
3
by: Will Atkinson | last post by:
Hi All, I'm a relative newbie to SQL Server, so please forgive me if this is a daft question... When I set "Show Execution Plan" on in Query Analyzer, and execute a (fairly complex) sproc, I...
2
by: Jenny Zhang | last post by:
Hi, I am running OSDL-DBT3 test against PostgreSQL. I found performance difference between the runs even though the data and queries are the same. I tried to study this problem by getting...
2
by: Jenny Zhang | last post by:
The osdl-dbt3 test starts with building and vacuuming the database. The execution plans were taken after the vacuuming. I did two tests with the same database parameters: 1. run two osdl-dbt3...
3
by: Kumar | last post by:
Hi, I have a table (TAB1) withi has 4 child tables on COL1 with DELETE CASCADE. When I delete any row in TAB1, it will delete corresponding rows on all child tables. SQL : delete from TAB1...
4
by: cbrichards via SQLMonster.com | last post by:
I have a stored procedure that will execute with less than 1,000 reads one time (with a specified set of parameters), then with a different set of parameters the procedure executes with close to...
5
by: sqlgirl | last post by:
Hi, We are trying to solve a real puzzle. We have a stored procedure that exhibits *drastically* different execution times depending on how its executed. When run from QA, it can take as...
2
by: uwcssa | last post by:
is there a way to see the actual (not just estimated) cost and cardinality at each plan operator? SQL Server and Oracle has such feature but I failed to find a way in DB2 yet (up to V9.5)
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.