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
 

 

What is RC = -1 here in REXX DB2 connectivity ?

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

Active User


Joined: 19 Mar 2009
Posts: 181
Location: Globe, India

PostPosted: Fri Jul 16, 2010 6:50 pm    Post subject: What is RC = -1 here in REXX DB2 connectivity ?
Reply with quote

Pls help me out over here...! It is saying connection error with Return code as -1... i am not able to debug this. I checked out the DSN1 name .. it is right !

Please help me in this.

/* rexx */
/* Check for the DSNREXX environment */
address tso 'subcom dsnrexx'
if rc \= 0 then
do
/* Add DSNREXX to the REXX host command environment table */
RC=RXSUBCOM('ADD','DSNREXX','DSNREXX')
end
if rc = 0 then
say 'dsnrexx to rexx host environment has been added successfully'
else
say 'error: dsnrexx could not be added in rexx host environment'

/* Connecting to DB2 Subsystem */
ADDRESS DSNREXX 'CONNECT' DSN1
say rc
if rc = 0 then
say 'connection established successfully'
else
say 'connection error'
Back to top
View user's profile Send private message

PeterHolland

Global Moderator


Joined: 27 Oct 2009
Posts: 2435
Location: Netherlands, Amstelveen

PostPosted: Fri Jul 16, 2010 7:00 pm    Post subject:
Reply with quote

Use 'SUBCOM DSNREXX' instead of address tso 'subcom dsnrexx'
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 I want to retire TRX and use only Rex... Abhinav Sharma CLIST & REXX 4 Sat Jul 29, 2017 2:53 am
No new posts Iterative use of a REXX script causin... bryonyh CLIST & REXX 4 Fri Jul 28, 2017 12:52 pm
No new posts Passing data from REXX to C programme... chong.zhou CLIST & REXX 3 Wed Jul 26, 2017 9:11 pm
No new posts REXX to get the all datasets name parasmalik20 CLIST & REXX 5 Tue Jul 18, 2017 9:10 pm
No new posts How system know which REXX to excute? jackzhang75 CLIST & REXX 14 Thu Jul 06, 2017 1:09 am


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