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

Move the content of ps file to db2 table & Vise versa


IBM Mainframe Forums -> Mainframe Interview Questions
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
nandakumar
Warnings : 2

New User


Joined: 05 May 2005
Posts: 50

PostPosted: Tue Jun 07, 2005 7:49 pm
Reply with quote

hi,
how to move the content of ps file to db2 table.
how to move the content of db2 table to ps file






thanks in advance.
Back to top
View user's profile Send private message
priya

Moderator


Joined: 24 Jul 2003
Posts: 568
Location: Bangalore

PostPosted: Tue Jun 07, 2005 8:37 pm
Reply with quote

Use UPLOAD utility
Back to top
View user's profile Send private message
nandakumar
Warnings : 2

New User


Joined: 05 May 2005
Posts: 50

PostPosted: Wed Jun 08, 2005 5:06 pm
Reply with quote

hi,
i want screen shot example for:
1) To move the content of ps file to db2 table.
2) To move the content of db2 table to ps file

Iam undergoing mainframe training now only,there we are not using load utility at all ,so can u plz give me some other method.

thanking u.
Back to top
View user's profile Send private message
sudheer648

New User


Joined: 23 May 2005
Posts: 97
Location: Chennai

PostPosted: Thu Jun 16, 2005 3:09 pm
Reply with quote

Hi Priya,

Quote:
Use UPLOAD utility


Please could elaborate something about this utility am not aware of this utility.
Back to top
View user's profile Send private message
MGIndaco

Active User


Joined: 10 Mar 2005
Posts: 432
Location: Milan, Italy

PostPosted: Thu Jun 16, 2005 9:06 pm
Reply with quote

To load data to DB2 from a PS(in UNLOAD format) you must have the SYSPUCH appropriate and adapt the PS layout to syspunch to be loaded.
If you want to load to DB2 a content of PS that is in IMAGECOPY format then the process is different.
This is the link to IBM Information Management Software to retrieve all the answers to your questions:
Load:
http://publib.boulder.ibm.com/infocenter/dzichelp/index.jsp?topic=/com.ibm.db2.doc.ugref/bjnbmstr35.htm

Samples of Load from IBM Manuals:
http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/handheld/Connected/BOOKS/DSNUG0F6/2.8.4.1?SHELF=&DT=20000421183700&CASE=

To unload data from DB2 to a PS you can use a simple UNLOAD that can extracts all the data of the table in its original dataformat or readapt, fields, format and other to your personal need.
These are two samples of unload:
1)Unload all:
Code:
//STEP010U EXEC PGM=DSNTIAUL
//STEPLIB  DD DISP=SHR,DSN=...steplib
//WFH....  DD DUMMY                                   
//SYSTSPRT DD SYSOUT=*                                 
//SYSPRINT DD SYSOUT=*                                 
//SYSUDUMP DD SYSOUT=*                                 
//SYSPUNCH DD SYSOUT=*
//SYSREC00 DD DSN=myoutput,     
//            DISP=(,CATLG,),SPACE=(CYL,(20,10),RLSE),
//            UNIT=SYSDA                           
//SYSIN    DD *                                       
mytable


2)Unload with select:
Code:
//STEP010U EXEC PGM=DSNTIAUL,PARM='SQL'
//STEPLIB  DD DISP=SHR,DSN=...steplib
//WFH....  DD DUMMY                                   
//SYSTSPRT DD SYSOUT=*                                 
//SYSPRINT DD SYSOUT=*                                 
//SYSUDUMP DD SYSOUT=*                                 
//SYSPUNCH DD SYSOUT=*
//SYSREC00 DD DSN=myoutput,     
//            DISP=(,CATLG,),SPACE=(CYL,(20,10),RLSE),
//            UNIT=SYSDA                           
//SYSIN    DD *                                       
SELECT *  FROM mytable;


This is the link to IBM to retrieve all the parameters and informations:
http://publib.boulder.ibm.com/infocenter/dzichelp/index.jsp?topic=/com.ibm.db2.doc.ugref/bjnbmstr35.htm
Back to top
View user's profile Send private message
sudheer648

New User


Joined: 23 May 2005
Posts: 97
Location: Chennai

PostPosted: Fri Jun 17, 2005 4:11 pm
Reply with quote

MGIndaco,

Its too good.Hats off for your search.
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 -> Mainframe Interview Questions

 


Similar Topics
Topic Forum Replies
No new posts Compare 2 files and retrive records f... DFSORT/ICETOOL 3
No new posts FTP VB File from Mainframe retaining ... JCL & VSAM 8
No new posts Extract the file name from another fi... DFSORT/ICETOOL 6
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts Extracting Variable decimal numbers f... DFSORT/ICETOOL 17
Search our Forums:

Back to Top