Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
DB2 v9.1 RID function

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

New User


Joined: 03 Apr 2008
Posts: 82
Location: United States

PostPosted: Thu May 10, 2012 2:28 am    Post subject: DB2 v9.1 RID function
Reply with quote

Hi All,

We are using DB2 V9.1 and trying to use RID function by using a select query like this

Code:
SELECT RID(TABLE1) FROM TABLE1
WHERE  COL1 = '1234567';


However we are getting this response:

Code:
SQLCODE = -206, ERROR:  TABLE1 IS NOT VALID IN THE CONTEXT WHERE
IT IS USED


We are aware that RID can be used in this version, but unsure where we are getting it wrong. Any ideas?
Back to top
View user's profile Send private message

dbzTHEdinosauer

Global Moderator


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

PostPosted: Thu May 10, 2012 4:09 am    Post subject:
Reply with quote

you may wish to see the value returned by 3.2.52 GETVARIABLE,
using SYSIBM.NEWFUN from the list contained (and explained) in 2.18.9 References to built-in session variables
Back to top
View user's profile Send private message
T-Rex

New User


Joined: 26 Oct 2007
Posts: 1
Location: Bonn

PostPosted: Thu May 10, 2012 4:18 pm    Post subject:
Reply with quote

I tried the Sample from the SQL Reference:

SELECT RID(DSN8910.EMP), LASTNAME
FROM DSN8910.EMP
WHERE EMPNO = '000020';


This works.
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 What is the Extract Function in JCL dharmaraok JCL & VSAM 3 Wed Jun 14, 2017 9:12 am
This topic is locked: you cannot edit posts or make replies. RANDOM Function in COBOL swapnil781 COBOL Programming 2 Tue Nov 15, 2016 6:17 pm
No new posts Check System time(Minute) Using TIME1... balaji81_k DFSORT/ICETOOL 5 Fri Nov 11, 2016 10:53 am
No new posts Strange EXEC function call in z/VM Willy Jensen CLIST & REXX 3 Wed Oct 05, 2016 2:07 pm
No new posts Replace function abdulrafi COBOL Programming 13 Mon Sep 12, 2016 10:12 am

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us