View previous topic :: View next topic
|
Author |
Message |
hallecodec
New User
Joined: 05 Sep 2006 Posts: 30 Location: Philippines
|
|
|
|
hi guys,
what utility would you suggest that is fast enough for downloading a db2 table which contains 655k+ records? thanks in advance for your replies. |
|
Back to top |
|
|
prav_06 Warnings : 1 Active User
Joined: 13 Dec 2005 Posts: 154 Location: The Netherlands
|
|
|
|
hi ,
Try the below jcl
Code: |
//STEP01 EXEC PGM=IKJEFT01,DYNAMNBR=20,REGION=0M
//SYSPUNCH DD DSN=SYSPUNCH.dataset,DISP=SHR
//SYSREC00 DD DSN=UNLOAD.dataset,DISP=SHR
//SYSPRINT DD SYSOUT=*
//SYSUDUMP DD SYSOUT=*
//SYSTSPRT DD SYSOUT=*
//SYSTSIN DD *
DSN SYSTEM(DB2D)
RUN PROGRAM(DSNTIAUL) PLAN(DSNTIAUL) -
LIB('DB2D.RUNLIB.LOAD')
/*
//SYSIN DD *
TABLE NAME |
/*
If u having more records in the table allocate sufficiant space for the data set in SYSREC00 DD name
And the parameters given inside the SYSTSIN would be varying according to installations.
Thamilzan. |
|
Back to top |
|
|
ballalsachin
New User
Joined: 22 Sep 2005 Posts: 15 Location: USA
|
|
|
|
hi,
you can go to D;D;6;3.7 Option in ISPF.
This is Fileaid Db2 option: 'Extract and Load Tables '
There is an option to use batch or online mode.
use the batch mode to download the table in a dataset.
remember to allocate enough space for the dataset that you are downloading your table into..
Sachin Ballal |
|
Back to top |
|
|
lekshmi_ci
New User
Joined: 14 Mar 2007 Posts: 60 Location: Thiruvananthapuram
|
|
|
|
But, if we want to do a selective download from the table,what to do?
can we write the query inside the sysin dd *?
please suggest a solution.............. |
|
Back to top |
|
|
guptae
Moderator
Joined: 14 Oct 2005 Posts: 1208 Location: Bangalore,India
|
|
|
|
Hi Lekshmi,
Yes we can write a query in SYSIN |
|
Back to top |
|
|
lekshmi_ci
New User
Joined: 14 Mar 2007 Posts: 60 Location: Thiruvananthapuram
|
|
|
|
When i entered the query to select the needed fields in the SYSIN statement the following error occured
SQL ERROR DURING SQL STATEMENT PREPARE , TABLE SELECT AGENT_JOB_C FROM PPSD4.AGENT;
SQLCODE = -199, ERROR: ILLEGAL USE OF KEYWORD FROM, TOKEN FOR WITH FETCH ORDER UNION EXCEPT QUERYNO OPTIMIZE
WAS EXPECTED
Please let me know how to solve this. |
|
Back to top |
|
|
guptae
Moderator
Joined: 14 Oct 2005 Posts: 1208 Location: Bangalore,India
|
|
|
|
Hi There,
Is PPSD4 is ur TSO id? |
|
Back to top |
|
|
lekshmi_ci
New User
Joined: 14 Mar 2007 Posts: 60 Location: Thiruvananthapuram
|
|
|
|
ppsd4.agent is fine....that s our table location. I could unload the data when i gave a full unload without any DB2 query. but this failed when i gave a selective unload. |
|
Back to top |
|
|
|