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

Can we pass the parameter to unload card


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

New User


Joined: 09 Dec 2006
Posts: 56
Location: Pune

PostPosted: Tue Aug 11, 2009 12:16 pm
Reply with quote

Hi,

I need to unload the data from the table for the current date. I need the data by compairing some table fields e.g.

Code:
SELECT A.ACCT, A.DATE_START
FROM BAL A                   
WHERE A.INDC_DATE_END = ' ' AND           
       A.ACCT IN (                   
SELECT C.NBR_CARDH_ACCT                       
FROM ACCT C                 
     WHERE C.DATE_START = '&&DATE' AND 
           C.ACCT IN (               
SELECT B.ACCT                       
FROM ACCT_ID B             
WHERE B.INDC_ACTIVE = 'Y'

As I mentined in above query in place of &&DATE, need to pass date coming from the input file.

In JCL we can pass the parameter, likewise can we pass the parameter to unload card? I am using FASTUNLOAD utility of platinum plus.

2. Also how can we mention parameter in sortcard if it is exceding more than 80 bytes?
Back to top
View user's profile Send private message
Help-Me-Out

New User


Joined: 09 Dec 2006
Posts: 56
Location: Pune

PostPosted: Tue Aug 11, 2009 2:01 pm
Reply with quote

Thanks!!
I know how to pass parameter within jcl. In same way trying to pass to fastunload utility but not able to do so. Also tried searching the forum but fail to get the answer...
Can you provide hint/help in this case...
Back to top
View user's profile Send private message
Skolusu

Senior Member


Joined: 07 Dec 2007
Posts: 2205
Location: San Jose

PostPosted: Tue Aug 11, 2009 9:09 pm
Reply with quote

Quote:

I need to unload the data from the table for the current date. I need the data by compairing some table fields


I am not sure as to why this question is in DFSORT forum but you can directly code "current date" parm in your sql itself like shown below

Code:

SELECT A.ACCT
      ,A.DATE_START
  FROM BAL A
 WHERE A.INDC_DATE_END = ' '
   AND A.ACCT IN (SELECT C.NBR_CARDH_ACCT
                    FROM ACCT C
                   WHERE C.DATE_START = CURRENT DATE
                     AND C.ACCT IN (SELECT B.ACCT
                                      FROM ACCT_ID B
                                     WHERE B.INDC_ACTIVE = 'Y')
Back to top
View user's profile Send private message
Ketan Varhade

Active User


Joined: 29 Jun 2009
Posts: 197
Location: Mumbai

PostPosted: Thu Aug 13, 2009 12:56 pm
Reply with quote

I am not sure that but if u want to pass the date field from a file then u can use SYMNAME, I haven't used SYMNAME while unloading but may be possible that it will help you to achive the desired result
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 Load new table with Old unload - DB2 DB2 6
No new posts JCL sort card - get first day and las... JCL & VSAM 9
No new posts Remote Unload of CLOB Columns DB2 6
No new posts Multiple table unload using INZUTILB DB2 2
No new posts How to pass the PARM value to my targ... COBOL Programming 8
Search our Forums:

Back to Top