IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Why SET statement cannot be prepared by REXX?


IBM Mainframe Forums -> DB2
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
dejunzhu

Active User


Joined: 08 May 2008
Posts: 390
Location: China

PostPosted: Tue Jul 22, 2014 8:59 pm
Reply with quote

I'm trying to execute a sql with REXX like :
Code:
SET :NEXT_DAY = DAYS(:CURR_DAY) + 1 DAYS

but when I prepare it , always error , even I changed host variables into '?', can anybody help me on this? thanks.
Back to top
View user's profile Send private message
Craq Giegerich

Senior Member


Joined: 19 May 2007
Posts: 1512
Location: Virginia, USA

PostPosted: Tue Jul 22, 2014 9:09 pm
Reply with quote

What sql code or error messages are you getting when you try?
Back to top
View user's profile Send private message
Marso

REXX Moderator


Joined: 13 Mar 2006
Posts: 1353
Location: Israel

PostPosted: Wed Jul 23, 2014 1:34 pm
Reply with quote

SET statement don't need to be PREPAREd, just EXECSQL it.
Back to top
View user's profile Send private message
Craq Giegerich

Senior Member


Joined: 19 May 2007
Posts: 1512
Location: Virginia, USA

PostPosted: Wed Jul 23, 2014 6:09 pm
Reply with quote

Quote:
I'm trying to execute a sql with REXX like :
Code:
SET :NEXT_DAY = DAYS(:CURR_DAY) + 1 DAYS

but when I prepare it , always error , even I changed host variables into '?', can anybody help me on this? thanks.


Suggest you look up the DAYS function in the sql manual.
Try:
Code:

Set :NEXT_DAY = DATE(:CURR_DAY) + 1 DAYS
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DB2

 


Similar Topics
Topic Forum Replies
No new posts Compile Several JCL JOB Through one r... CLIST & REXX 4
No new posts Running REXX through JOB CLIST & REXX 13
No new posts Error to read log with rexx CLIST & REXX 11
No new posts isfline didnt work in rexx at z/OS ve... CLIST & REXX 7
No new posts run rexx code with jcl CLIST & REXX 15
Search our Forums:

Back to Top