View previous topic :: View next topic
|
Author |
Message |
varabandi
New User
Joined: 07 Mar 2005 Posts: 2
|
|
|
|
I have few quetions on DB2. please answer those...
1. How to read records from table in Back words Using Cursor.
2. How to solve -818 .
3. How Optimizer works? What does it do?
4. how to solve soc-7 in effctive way if it is production? |
|
Back to top |
|
|
laxmi
New User
Joined: 24 May 2005 Posts: 9
|
|
|
|
1) by using scrollable cursors we can read backward and forward
the option is ABSOLUTELY N so that it fetches N records from the beginning
RELATIVELY N it fetches N records from the last record
i think it is sufficient if u have any doubts let me know |
|
Back to top |
|
|
asr1983
New User
Joined: 31 May 2005 Posts: 11
|
|
|
|
Hi varabandi,
Sql code -818 occurs because of the timestamp mismatch between pre-compiler and bind.
Solution is to pre-compile and bind it again
Let me know if any other solutions.
Regards,
Ram |
|
Back to top |
|
|
khamarutheen
Active Member
Joined: 23 Aug 2005 Posts: 677 Location: NJ
|
|
|
|
hi frnd,
S0C7 is the common error in mainframe tech.
here is the solution to solve it:
>>>Basically you need to correcting the offending data. Many times the reason for SOC7 is an un-initialized numeric item.
>>>Examine that possibility first. Many installations provide you a dump for run time abend?s ( it can be generated also
by calling some subroutines or OS services thru assembly language).
>>> Examine the compilation output XREF listing to get the verb and the line number of the source code at this offset.
>>> Then you can look at the source code to find the bug. To get capture the runtime dumps, you will have to define some datasets (SYSABOUT etc ) in the JCL.
>>>If none of these are helpful, use judgement and DISPLAY to localize the source of error.
>>>Some installation might have batch program debugging tools. Use them.
hope enough |
|
Back to top |
|
|
tam
New User
Joined: 02 Nov 2005 Posts: 12 Location: zz
|
|
|
|
DB2 optimizer selects the best access paths for executing the Sql Statements. Whenever a Dynamic SQl statement is issued the DB2 optimizer reads the system catalog tables to review the available indexes, the size of each table, the characteristics of the column, and other information to select the bets access path for executing the query.[/b] |
|
Back to top |
|
|
|