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: 179
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: 2429
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 REXX cdoe to purge a JOB from spool a... Sulabh Agrawal CLIST & REXX 11 Thu Mar 09, 2017 11:36 am
No new posts Overriding PS data in rexx Shaheen Shaik CLIST & REXX 8 Fri Mar 03, 2017 5:08 pm
No new posts REXX compiled via RXTCOMP sergeyken CLIST & REXX 7 Tue Feb 07, 2017 9:41 pm
This topic is locked: you cannot edit posts or make replies. Calling REXX code from ISPF panel sanchita dey TSO/ISPF 4 Mon Jan 02, 2017 5:13 pm
No new posts REXX DB2: Dynamic allocation of DB2.D... BHAS CLIST & REXX 3 Mon Dec 19, 2016 8:26 pm


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