IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Can anyboddy explain what is "QUERYNO" in select


IBM Mainframe Forums -> DB2
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
soumyaranjan007

New User


Joined: 30 Aug 2006
Posts: 30
Location: mumbai

PostPosted: Wed Feb 20, 2008 3:56 pm
Reply with quote

Hi,

Query is as like below


EXEC SQL
SELECT
Column 1,
Column 2
Into
:c1,
:c2
from Table_A
where Column 3 = :c3
QUERYNO 15101
END-EXEC.

Thanks
Soumya
Back to top
View user's profile Send private message
CICS Guy

Senior Member


Joined: 18 Jul 2007
Posts: 2146
Location: At my coffee table

PostPosted: Wed Feb 20, 2008 4:29 pm
Reply with quote

Have you looked at the fine manual?
QUERYNO integer
Specifies the number to be used for this SQL statement in EXPLAIN output and trace records. The number is used for the QUERYNO columns of the plan tables for the rows that contain information about this SQL statement. This number is also used in the QUERYNO column of the SYSIBM.SYSSTMT and SYSIBM.SYSPACKSTMT catalog tables.
Back to top
View user's profile Send private message
soumyaranjan007

New User


Joined: 30 Aug 2006
Posts: 30
Location: mumbai

PostPosted: Thu Feb 21, 2008 5:49 pm
Reply with quote

what is the benefits to use QUERYNO ?
Could any one please send me the manual please?
Back to top
View user's profile Send private message
rajeshrs488

New User


Joined: 21 Feb 2008
Posts: 3
Location: Banglore

PostPosted: Thu Feb 21, 2008 5:58 pm
Reply with quote

this is inside the plan table.optimiser tuk the best path
nad also contain the information about the sql statement
Back to top
View user's profile Send private message
acevedo

Active User


Joined: 11 May 2005
Posts: 344
Location: Spain

PostPosted: Thu Feb 21, 2008 6:22 pm
Reply with quote

soumyaranjan007 wrote:
what is the benefits to use QUERYNO ?
Could any one please send me the manual please?


search for EXPLAIN in the db2 manuals

publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/LIBRARY
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DB2

 


Similar Topics
Topic Forum Replies
No new posts PuTTY - "User is not a surrogate... IBM Tools 5
No new posts Dynamically pass table name to a sele... DB2 2
No new posts DB2 Statistics - Using EXPLAIN and qu... DB2 1
No new posts SELECT from data change table DB2 5
No new posts Select two different counts from SQL... DB2 6
Search our Forums:

Back to Top