DB2 interview question on fetching rows.

All sort of Mainframes Interview Questions.
Post Reply
Sanjay Mainframe
Registered Member
Posts: 10
Joined: Tue Mar 18, 2014 11:16 am

DB2 interview question on fetching rows.

Post by Sanjay Mainframe »

Hi All,

I have been asked this interview question which I could not answer - How to fetch multiple rows and move to output(30 occurrences)?

Can someone please help me with some answer or direction.
User avatar
Anuj Dhawan
Founder
Posts: 2802
Joined: Sun Apr 21, 2013 7:40 pm
Location: Mumbai, India
Contact:
India

Re: DB2 interview question on fetching rows.

Post by Anuj Dhawan »

CURSOR with or without ROWSET POSITIONING can be used. 'Host-variable-array' should be defined with 30-occurrences for your example.

Hope this helps.
Thanks,
Anuj

Disclaimer: My comments on this website are my own and do not represent the opinions or suggestions of any other person or business entity, in any way.
Post Reply

Create an account or sign in to join the discussion

You need to be a member in order to post a reply

Create an account

Not a member? register to join our community
Members can start their own topics & subscribe to topics
It’s free and only takes a minute

Register

Sign in

Return to “Interview Questions.”