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
 

 

DB2 UDB Stored Procedure "Select Into" with -811

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DB2
View previous topic :: :: View next topic  
Author Message
Lenny2113

New User


Joined: 20 Dec 2009
Posts: 2
Location: USA

PostPosted: Thu Jul 08, 2010 5:59 pm    Post subject: DB2 UDB Stored Procedure "Select Into" with -811
Reply with quote

Hi all,
I have a UDB Stored Procedure which has "Select into". It returns -811 and does not retrieve any rows into host variables.
Any suggestions why? (Besides cursor)

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

dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6968
Location: porcelain throne

PostPosted: Thu Jul 08, 2010 6:04 pm    Post subject:
Reply with quote

because an -811 (in release vsn7 and above)
does not populate any host variables.
Back to top
View user's profile Send private message
Lenny2113

New User


Joined: 20 Dec 2009
Posts: 2
Location: USA

PostPosted: Thu Jul 08, 2010 8:20 pm    Post subject:
Reply with quote

Thank you! Will do cursor
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6968
Location: porcelain throne

PostPosted: Thu Jul 08, 2010 8:23 pm    Post subject:
Reply with quote

glad we were able to help.
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6968
Location: porcelain throne

PostPosted: Fri Jul 09, 2010 12:09 am    Post subject:
Reply with quote

Sorry it took me so long to think of it,

but you can put a:
FETCH FIRST ROW ONLY
clause in the singleton select and you don't have to deal with cursors.
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 -> DB2 All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Changeman get multiple "Browse C... elixir1986 Compuware & Other Tools 4 Fri Jul 14, 2017 1:48 am
No new posts SQL - select data available in index Nileshkul DB2 3 Mon Jun 26, 2017 1:30 am
No new posts Include/omit with "ALL" pa... mgl DFSORT/ICETOOL 6 Wed Jun 14, 2017 2:31 pm
No new posts READ A PACKED "NEGATIVE" FI... jdesouza CA Products 3 Tue May 02, 2017 11:43 pm
No new posts RC 20 for Address ISPEXEC "ISRED... pkmurali CLIST & REXX 3 Sun Apr 16, 2017 11:30 pm


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