Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

After retrieving records using cursors, can perform update

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> Mainframe Interview Questions
View previous topic :: :: View next topic  
Author Message
sandhyamf
Warnings : 1

New User


Joined: 07 Feb 2007
Posts: 3
Location: hyderabad

PostPosted: Fri Feb 09, 2007 3:55 pm    Post subject: After retrieving records using cursors, can perform update
Reply with quote

Hi,

After retrieving records using cursors,how can perform update?
What is the max size of working storage section?
What is onsize error in cobol?

Regards,
Sandhya.
Back to top
View user's profile Send private message

manihcl85
Warnings : 1

New User


Joined: 11 Jan 2007
Posts: 52
Location: chennai

PostPosted: Fri Feb 09, 2007 6:06 pm    Post subject: Update after retriving records using cursor
Reply with quote

Hi,

U have to use update cursor cursorname set fieldname = value where "record u want to update" or "current of cursor for updating the current record"

Regards,
Mani
Back to top
View user's profile Send private message
manihcl85
Warnings : 1

New User


Joined: 11 Jan 2007
Posts: 52
Location: chennai

PostPosted: Fri Feb 09, 2007 6:18 pm    Post subject: On size error
Reply with quote

Hi,

onsize error is an function to say what to do in case if any overflow or error due to size of an variable occured.

Regards,
Mani
Back to top
View user's profile Send private message
mmwife

Super Moderator


Joined: 30 May 2003
Posts: 1592

PostPosted: Sat Feb 10, 2007 5:19 am    Post subject:
Reply with quote

You can also get a SIZE ERROR dividing by zero or when using windowed date fields (I've never used these date fields, so I have no details.)
Back to top
View user's profile Send private message
hanu_010

New User


Joined: 25 Jan 2007
Posts: 9
Location: hyd

PostPosted: Thu Mar 01, 2007 11:02 pm    Post subject:
Reply with quote

FOR UPDATE OF IS DECLARED IN DECLARE CURSOR

AFTER FETCH


WE UPDATE THE COLUMNS AND SHOULD CODE WHERE CURRENT OF
Back to top
View user's profile Send private message
hanu_010

New User


Joined: 25 Jan 2007
Posts: 9
Location: hyd

PostPosted: Thu Mar 01, 2007 11:08 pm    Post subject:
Reply with quote

ON SIZE ERROR IS USING TO TRAP THE SIZE ERRORS

01 A PIC 99.
01 B PIC 99.
01 C PIC 99.

COMPUTE C = A + B.

A=90
B=10

AFTER CALUCLATION A + B = 100,

BUT C HAS A PIC 99.

SO FINAL RESULT WILL BE 00

SO THERE IS SIZE ERROR

TO AVOID THIS WE HAVE TO USE ON SIZE ERROR

COMPUTE C = A +B ON SIZE ERROR DISPLAY ' SIZE ERROR'
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> Mainframe Interview Questions All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Removing Duplicates based on certain ... chandracdac DFSORT/ICETOOL 8 Fri Dec 09, 2016 4:40 am
No new posts Limit duplicate records in the SORT pshongal SYNCSORT 6 Mon Nov 21, 2016 12:54 pm
No new posts -913/-911 Deadlock during UPDATE stat... NoSleep319 DB2 5 Fri Nov 18, 2016 12:37 am
No new posts How to update a portion of text in a ... Bill Woodger DFSORT/ICETOOL 25 Wed Nov 09, 2016 9:41 pm
No new posts Updating Cursor row withour using FOR... chandan.inst DB2 15 Tue Nov 08, 2016 11:17 am


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us