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

File open failure saying tape not supported


IBM Mainframe Forums -> DFSORT/ICETOOL
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
jagjit

New User


Joined: 28 Dec 2006
Posts: 18
Location: india

PostPosted: Wed Dec 17, 2008 5:13 pm
Reply with quote

I am unable to open the file getting generated through jcl and it says "tape not supported" . Can I use DFSORT for creating some other file which copy the data of file so that i can able to view it
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8696
Location: Dubuque, Iowa, USA

PostPosted: Wed Dec 17, 2008 6:30 pm
Reply with quote

Quote:
I am unable to open the file getting generated through jcl and it says "tape not supported"
If you say something like this, you need to post your JCL and the exact error message -- at a minimum -- to get any kind of help that is not wild guessing.
Back to top
View user's profile Send private message
Skolusu

Senior Member


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

PostPosted: Wed Dec 17, 2008 11:22 pm
Reply with quote

I am guessing that jagjit was trying to browse a tape file from ISPF. (3.4) .

Jagjit,

ISPF does not support tape browsing. You need to have the file on DASD. you can use the following DFSORT JCL to copy the contents of the tape file onto a dasd file . I suggest that you copy only a few records say 1000 or else you might run into B37 space errors.


Code:

//STEP0100 EXEC PGM=ICEMAN           
//SYSOUT   DD SYSOUT=*               
//SORTIN   DD DSN=your input TAPE,DISP=SHR
//SORTOUT  DD DSN=your DASD file to browse,       
//            DISP=(NEW,CATLG,DELETE),
//            UNIT=SYSDA,             
//            SPACE=(CYL,(10,10),RLSE) 
//SYSIN    DD *                       
  OPTION COPY,STOPAFT=1000               
/*
Back to top
View user's profile Send private message
jagjit

New User


Joined: 28 Dec 2006
Posts: 18
Location: india

PostPosted: Wed Jan 07, 2009 2:13 pm
Reply with quote

Skolusu,

Thanks for your kind help. May i Know if it is possible to get first 100 and last 100 records of tape file in my output DASD file. Actually my tape file contains header and trailer which i need to verify. Please help for the same
Back to top
View user's profile Send private message
loverj24

New User


Joined: 05 Jul 2007
Posts: 16
Location: bangalore

PostPosted: Wed Jan 07, 2009 2:34 pm
Reply with quote

Hi Jagjit,

You can use the following code to get Both the requirements in the same JCl.
Code:

//STEP0100 EXEC PGM=ICEMAN           
//SYSOUT   DD SYSOUT=*               
//SORTIN   DD DSN=your input TAPE,DISP=SHR
//SORTOUT  DD DSN=your DASD file to browse,       
//            DISP=(NEW,CATLG,DELETE),
//            UNIT=SYSDA,             
//            SPACE=(CYL,(10,10),RLSE) 
//SYSIN    DD *                       
  OPTION COPY,STOPAFT=1000               
/*
//STEP0200 EXEC PGM=ICEMAN           
//SYSOUT   DD SYSOUT=*               
//SORTIN   DD DSN=your input TAPE,DISP=SHR
//SORTOUT  DD DSN=your 2nd output File,       
//            DISP=(NEW,CATLG,DELETE),
//            UNIT=SYSDA,             
//            SPACE=(CYL,(10,10),RLSE) 
//SYSIN    DD *                       
  OPTION COPY,SKIPREC=900               
/*
Back to top
View user's profile Send private message
jagjit

New User


Joined: 28 Dec 2006
Posts: 18
Location: india

PostPosted: Wed Jan 07, 2009 2:46 pm
Reply with quote

Loverj24,

Thanks. Actually i forget to add that my tape file is having say 57 lakh records so will "SKIPREC" work if i give SKIPREC=5699800
Back to top
View user's profile Send private message
loverj24

New User


Joined: 05 Jul 2007
Posts: 16
Location: bangalore

PostPosted: Wed Jan 07, 2009 2:48 pm
Reply with quote

Yes It will.
Back to top
View user's profile Send private message
jagjit

New User


Joined: 28 Dec 2006
Posts: 18
Location: india

PostPosted: Wed Jan 07, 2009 2:51 pm
Reply with quote

Is it not possible to get both 1st 100 and last 100 records in the same file. As i have some 50 tape files to check. Please let me know.
Back to top
View user's profile Send private message
loverj24

New User


Joined: 05 Jul 2007
Posts: 16
Location: bangalore

PostPosted: Wed Jan 07, 2009 3:00 pm
Reply with quote

This is what you would want to use
Code:

//STEP0100 EXEC PGM=ICEMAN           
//SYSOUT   DD SYSOUT=*               
//SORTIN   DD DSN=your input TAPE,DISP=SHR
//SORTOUT  DD DSN=your 1st 100 records file,       
//            DISP=(NEW,CATLG,DELETE),
//            UNIT=SYSDA,             
//            SPACE=(CYL,(10,10),RLSE) 
//SYSIN    DD *                       
  OPTION COPY,STOPAFT=1000               
/*
//STEP0200 EXEC PGM=ICEMAN           
//SYSOUT   DD SYSOUT=*               
//SORTIN   DD DSN=your input TAPE,DISP=SHR
//SORTOUT  DD DSN=your 2nd records file,       
//            DISP=(NEW,CATLG,DELETE),
//            UNIT=SYSDA,             
//            SPACE=(CYL,(10,10),RLSE) 
//SYSIN    DD *                       
  OPTION COPY,SKIPREC=900               
/*
//STEPE0300  EXEC PGM=SORT                                 
//SORTLIB     DD DSN=SYS1.SORTLIB,DISP=SHR                 
//SORTIN      DD DSN=your 1st 100 records file,DISP=SHR           
//            DD DSN=your 2nd records file,DISP=SHR
//*                                                         
//SORTOUT     DD DSN=third file having data from 1st and 2nd,                   
//            DISP=(NEW,CATLG,DELETE)                       
//SYSIN     DD *     
 SORT FIELDS=COPY     
/*

Back to top
View user's profile Send private message
jagjit

New User


Joined: 28 Dec 2006
Posts: 18
Location: india

PostPosted: Wed Jan 07, 2009 3:17 pm
Reply with quote

I think i am not clear in my words. let me try once again.
I have TAPE file having 50 lakhs records. In ISPF i can't view tape file so for that i will create a DASD file and using DFSORT i wil copy records from TAPE file i.e. input file to output file.

Now i want to see or move only 1st 100 and last 100 records of my TAPE input file to my DASD file.

If you see in the very first screen shot given by Skolusu he is moving 1000 records to DASD file. Instead of that i want 1st 100 and last 100 records to be moved in my output DASD file. I hope this will give you clear idea about my requirement. Thanks Loverj24 for patience.
Back to top
View user's profile Send private message
loverj24

New User


Joined: 05 Jul 2007
Posts: 16
Location: bangalore

PostPosted: Wed Jan 07, 2009 3:56 pm
Reply with quote

Yes Jagjit, Did you try running the JCL that is given, In the Third step of the JCL you will get the file with the first 100 and the last 100. You will need to change the Skiprec and the Stopaft to the values that you want to have in the First and the second file
Back to top
View user's profile Send private message
Arun Raj

Moderator


Joined: 17 Oct 2006
Posts: 2481
Location: @my desk

PostPosted: Wed Jan 07, 2009 4:58 pm
Reply with quote

Quote:
he is moving 1000 records to DASD file. Instead of that i want 1st 100

Jagjit,

You can always change 1000 to 100 if you want 100. Also you can modify Kolusu's job to use the same SORTOUT file in both the steps and have a
Code:
DISP=(MOD,CATLG,DELETE)
in 2nd step if you want to combine the results from both the steps.
Back to top
View user's profile Send private message
jagjit

New User


Joined: 28 Dec 2006
Posts: 18
Location: india

PostPosted: Wed Jan 07, 2009 5:05 pm
Reply with quote

Thanks loverj and arun ....actually i m not mainframe guy....tats y kept u troubling...
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10873
Location: italy

PostPosted: Wed Jan 07, 2009 5:19 pm
Reply with quote

use the SUBSET operator

For complete details on the new SUBSET operator and the other new functions available with PTF UK90013, see:

Use [URL] BBCode for External Links

search for something like
Quote:
SUBSET FROM(IN) TO(OUT) KEEP INPUT FIRST(100) LAST(100)
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Developer


Joined: 15 Feb 2005
Posts: 7129
Location: San Jose, CA

PostPosted: Wed Jan 07, 2009 11:01 pm
Reply with quote

jagjit,

With the SKIPREC and STOPAFT solution, you have to know the number of records in the input file and figure out the SKIPREC and STOPAFT values.

You can do what you want much more easily using DFSORT's new SUBSET function. You don't have to know the number of records in the input file or do any calculations. Here's the DFSORT/ICETOOL job you can use:

Code:

//S1   EXEC  PGM=ICETOOL
//TOOLMSG   DD  SYSOUT=*
//DFSMSG    DD  SYSOUT=*
//IN   DD DSN=your input TAPE,DISP=SHR
//OUT  DD DSN=your DASD file to browse,
//            DISP=(NEW,CATLG,DELETE),
//            UNIT=SYSDA,
//            SPACE=(CYL,(10,10),RLSE)
//TOOLIN DD *
SUBSET FROM(IN) TO(OUT) INPUT KEEP FIRST(100) LAST(100)
/*


You'll need z/OS DFSORT V1R5 PTF UK90013 (July, 2008) to use DFSORT's new SUBSET function. If you don't have that PTF, ask your System Programmer to install it (it's free).

For complete details on the SUBSET function and the other new functions available with PTF UK90013, see:

Use [URL] BBCode for External Links
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 -> DFSORT/ICETOOL

 


Similar Topics
Topic Forum Replies
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
No new posts SFTP Issue - destination file record ... All Other Mainframe Topics 2
Search our Forums:

Back to Top