Retrive a specific record with out using cursor



IBM's flagship relational database management system

Retrive a specific record with out using cursor

Postby sandip kumar mondal » Thu Dec 09, 2010 11:09 pm

hi
i am sandip. i have a question.
In dynamic sql can we retrive a specific record with out using cursor???if yes then how can i display the record???
sandip kumar mondal
 
Posts: 6
Joined: Wed Dec 08, 2010 9:52 pm
Has thanked: 0 time
Been thanked: 0 time

Re: DB2

Postby Akatsukami » Thu Dec 09, 2010 11:16 pm

Of course. How depends on the host language.
"You have sat too long for any good you have been doing lately ... Depart, I say; and let us have done with you. In the name of God, go!" -- what I say to a junior programmer at least once a day
User avatar
Akatsukami
Global moderator
 
Posts: 1058
Joined: Sat Oct 16, 2010 2:31 am
Location: Bloomington, IL
Has thanked: 6 times
Been thanked: 51 times

Re: DB2

Postby enrico-sorichetti » Thu Dec 09, 2010 11:32 pm

the YES/NO question disease has struck again :D
cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort
enrico-sorichetti
Global moderator
 
Posts: 2994
Joined: Fri Apr 18, 2008 11:25 pm
Has thanked: 0 time
Been thanked: 164 times

Re: DB2

Postby dick scherrer » Fri Dec 10, 2010 1:46 am

Hello and welcome to the forum,

Do you now have what you are looking for?

If not, you need to explain where you are stuck. . .
Hope this helps,
d.sch.
User avatar
dick scherrer
Global moderator
 
Posts: 6268
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 93 times

Re: DB2

Postby RJAY » Fri Dec 10, 2010 7:30 am

Sandip - Where are you running the dynamic sql...? Need more information. In the mainframe world running a sql via qmf or spufi is considered to be a dynamic sql. In that sense "YES" you can run a dynamic sql to retrieve data without using a cursor.
RJAY
 
Posts: 3
Joined: Thu Dec 09, 2010 8:53 am
Has thanked: 0 time
Been thanked: 0 time

Re: DB2

Postby dick scherrer » Fri Dec 10, 2010 10:00 am

Hello,

Your post is misleading at best - if not simply incorrect . . .

Dynamic sql can be executed from within one's own code, not only SPUFI or QMF. And it may or may not use a cursor. . .
Hope this helps,
d.sch.
User avatar
dick scherrer
Global moderator
 
Posts: 6268
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 93 times

Re: Retrive a specific record with out using cursor

Postby sandip kumar mondal » Fri Dec 10, 2010 4:42 pm

i need the code.and my host language is cobol.and i use spufi to run those sql statements.
sandip kumar mondal
 
Posts: 6
Joined: Wed Dec 08, 2010 9:52 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Retrive a specific record with out using cursor

Postby NicC » Fri Dec 10, 2010 5:10 pm

If you need the code - write it! There is a COBOL Language Reference Manual and a SQL Language Reference Manual that you may need to consult.
The problem I have is that people can explain things quickly but I can only comprehend slowly.
Regards
Nic
NicC
Global moderator
 
Posts: 3025
Joined: Sun Jul 04, 2010 12:13 am
Location: Pushing up the daisies (almost)
Has thanked: 4 times
Been thanked: 136 times

Re: Retrive a specific record with out using cursor

Postby Robert Sample » Fri Dec 10, 2010 5:56 pm

This is a HELP forum, not a WRITE-THE-CODE-FOR-YOU forum. However, I'm sure a number of people who respond on this forum would write the code for you provided you pay the appropriate professional fee (rates usually run about U.S. dollars 700 to 1500 per day for professional work product). If you get stuck writing the code, ask for help -- but we're not going to just give you the code since you're not learning anything by that.
Robert Sample
Global moderator
 
Posts: 3719
Joined: Sat Dec 19, 2009 8:32 pm
Location: Dubuque, Iowa, USA
Has thanked: 1 time
Been thanked: 279 times


Return to DB2

 


  • Related topics
    Replies
    Views
    Last post