extract records from a file OS/390

Amit Agarwal

extract records from a file OS/390
I have a large file, and unable to open in the edit mode.
Can someone send me a sample JCL or REXX to extract 10 records from the file?

Thanks
Amit



--------------------------------------------------------
The information contained in this message is intended only for the recipient, and may be a confidential attorney-client communication or may otherwise be privileged and confidential and protected from disclosure. If the reader of this message is not the intended recipient, or an employee or agent responsible for delivering this message to the intended recipient, please be aware that any dissemination or copying of this communication is strictly prohibited. If you have received this communication in error, please immediately notify us by replying to the message and deleting it from your computer.

Thank you,

Standard & Poor's

--------------------------------------------------------





---------------------------------------------------------------------------------
Welcome to the IDUG DB2-L list. To unsubscribe, go to the archives and home page at http://www.idugdb2-l.org/archives/db2-l.html. From that page select "Join or Leave the list". If you will be out of the office, send the SET DB2-L NO MAIL command to [login to unmask email] The IDUG List Admins can be reached at [login to unmask email] Find out the latest on IDUG conferences at http://conferences.idug.org/index.cfm

Philip Sevetson

Re: extract records from a file OS/390
(in response to Amit Agarwal)
SYNCSORT or DFSORT have the ability to do this using SORT FIELDS=COPY and
STOPAFT=10 for the first ten records.

--Phil Sevetson
Database Administration
Wakefern Food Corporation CISD
mailto:[login to unmask email]






"Agarwal, Amit" <[login to unmask email]>
Sent by: DB2 Data Base Discussion List <[login to unmask email]>
12/04/2003 08:58 AM
Please respond to DB2 Database Discussion list at IDUG


To: [login to unmask email]
cc:
Subject: extract records from a file OS/390


I have a large file, and unable to open in the edit mode.
Can someone send me a sample JCL or REXX to extract 10 records from the
file?

Thanks
Amit

The information contained in this message is intended only for the
recipient, and may be a confidential attorney-client communication or may
otherwise be privileged and confidential and protected from disclosure. If
the reader of this message is not the intended recipient, or an employee
or agent responsible for delivering this message to the intended
recipient, please be aware that any dissemination or copying of this
communication is strictly prohibited. If you have received this
communication in error, please immediately notify us by replying to the
message and deleting it from your computer.
Thank you,
Standard & Poor's

---------------------------------------------------------------------------------
Welcome to the IDUG DB2-L list. To unsubscribe, go to the archives and
home page at http://www.idugdb2-l.org/archives/db2-l.html. From that page select "Join or Leave the list". If you will be out of
the office, send the SET DB2-L NO MAIL command to
[login to unmask email] The IDUG List Admins can be reached at
[login to unmask email] Find out the latest on IDUG conferences
at http://conferences.idug.org/index.cfm


---------------------------------------------------------------------------------
Welcome to the IDUG DB2-L list. To unsubscribe, go to the archives and home page at http://www.idugdb2-l.org/archives/db2-l.html. From that page select "Join or Leave the list". If you will be out of the office, send the SET DB2-L NO MAIL command to [login to unmask email] The IDUG List Admins can be reached at [login to unmask email] Find out the latest on IDUG conferences at http://conferences.idug.org/index.cfm

Mark Granger

Re: extract records from a file OS/390
(in response to Philip Sevetson)
Amit,

A repro is an easy way

//REPRO EXEC PGM=IDCAMS,REGION=4M
//REPIN DD DISP=SHR,DSN=Indataset,UNIT=SYSDA
//REPOUT DD DSN=Outdataset,DISP=(NEW,CATLG,DELETE),etc,etc
//SYSPRINT DD SYSOUT=*
//SYSIN DD *
REPRO INFILE(REPIN) OUTFILE(REPOUT) COUNT(10)
REPRO INFILE(REPIN) OUTFILE(REPOUT) SKIP(10) COUNT(10)
//


Mark Granger


----- Original Message -----
From: "Agarwal, Amit" <[login to unmask email]>
Date: Thursday, December 4, 2003 9:58 am
Subject: extract records from a file OS/390

> I have a large file, and unable to open in the edit mode.
> Can someone send me a sample JCL or REXX to extract 10 records
> from the file?
>
> Thanks
> Amit
>
>
>
> --------------------------------------------------------
> The information contained in this message is intended only for the
> recipient, and may be a confidential attorney-client communication
> or may otherwise be privileged and confidential and protected from
> disclosure. If the reader of this message is not the intended
> recipient, or an employee or agent responsible for delivering this
> message to the intended recipient, please be aware that any
> dissemination or copying of this communication is strictly
> prohibited. If you have received this communication in error,
> please immediately notify us by replying to the message and
> deleting it from your computer.
>
> Thank you,
>
> Standard & Poor's
>
> --------------------------------------------------------
>
>
>
>
>
> -------------------------------------------------------------------
> --------------
> Welcome to the IDUG DB2-L list. To unsubscribe, go to the archives
> and home page at http://www.idugdb2-l.or From that page select
> "Join or Leave the list". If you will be out of the office, send
> the SET DB2-L NO MAIL command to [login to unmask email] The
> IDUG List Admins can be reached at [login to unmask email]
> l.org. Find out the latest on IDUG conferences at
> http://conferences.idug.org/index.cfm

---------------------------------------------------------------------
Never lose a fax again, receive faxes to your personal email account!
Visit http://www.mbox.com.au/fax

---------------------------------------------------------------------------------
Welcome to the IDUG DB2-L list. To unsubscribe, go to the archives and home page at http://www.idugdb2-l.org/archives/db2-l.html. From that page select "Join or Leave the list". If you will be out of the office, send the SET DB2-L NO MAIL command to [login to unmask email] The IDUG List Admins can be reached at [login to unmask email] Find out the latest on IDUG conferences at http://conferences.idug.org/index.cfm

Alice Frus

Re: extract records from a file OS/390
(in response to Mark Granger)
Can you just copy it to a file that you know is too small and it will
truncate most of what you don't want anyway ?



"Agarwal, Amit"
<[login to unmask email] To:
[login to unmask email]
DPOORS.COM> cc:
Sent by: "DB2 Data Base Subject: extract
records from a file OS/390
Discussion List"
<[login to unmask email]>
12/04/2003 07:58 AM
Please respond to "DB2
Database Discussion list
at IDUG"




I have a large file, and unable to open in the edit mode.
Can someone send me a sample JCL or REXX to extract 10 records from the
file?

Thanks
Amit

The information contained in this message is intended only for the
recipient, and may be a confidential attorney-client communication or may
otherwise be privileged and confidential and protected from disclosure. If
the reader of this message is not the intended recipient, or an employee or
agent responsible for delivering this message to the intended recipient,
please be aware that any dissemination or copying of this communication is
strictly prohibited. If you have received this communication in error,
please immediately notify us by replying to the message and deleting it
from your computer.
Thank you,
Standard & Poor's

---------------------------------------------------------------------------------
Welcome to the IDUG DB2-L list. To unsubscribe, go to the archives and
home page at http://www.idugdb2-l.org/archives/db2-l.html. From that page
select "Join or Leave the list". If you will be out of the office, send the
SET DB2-L NO MAIL command to [login to unmask email] The IDUG List
Admins can be reached at [login to unmask email] Find out the
latest on IDUG conferences at http://conferences.idug.org/index.cfm



**********
The information contained in this communication is confidential, private,
proprietary, or otherwise privileged and is intended only for the use of the
addressee. Unauthorized use, disclosure, distribution or copying is strictly
prohibited and may be unlawful. If you have received this communication in
error, please notify the sender immediately at (312)653-6000 in Illinois;
(972)766-6900 in Texas; or (800)835-8699 in New Mexico.
**********

---------------------------------------------------------------------------------
Welcome to the IDUG DB2-L list. To unsubscribe, go to the archives and home page at http://www.idugdb2-l.org/archives/db2-l.html. From that page select "Join or Leave the list". If you will be out of the office, send the SET DB2-L NO MAIL command to [login to unmask email] The IDUG List Admins can be reached at [login to unmask email] Find out the latest on IDUG conferences at http://conferences.idug.org/index.cfm

Bill Brown

Re: extract records from a file OS/390
(in response to Alice Frus)
If you are version 7 you can use the limit parm on the unload utility.

---------------------------------------------------------------------------------
Welcome to the IDUG DB2-L list. To unsubscribe, go to the archives and home page at http://www.idugdb2-l.org/archives/db2-l.html. From that page select "Join or Leave the list". If you will be out of the office, send the SET DB2-L NO MAIL command to [login to unmask email] The IDUG List Admins can be reached at [login to unmask email] Find out the latest on IDUG conferences at http://conferences.idug.org/index.cfm

Bob Galeotti

Re: extract records from a file OS/390
(in response to Bill Brown)
Yes, sort of. If you create your output file in the SORT or IDCAMS step,
and let it abend with an SB37, and having defined the disposition as
follows: DISP=(NEW,CATLG,CATLG). Then the file will still exist after
the SB37.

Bob Galeotti, Sales Tech Support
SoftBase Systems, Inc.
800.669.7076 x372
[login to unmask email]
http://www.softbase.com/

----- Original Message -----
From: <[login to unmask email]>
Newsgroups: bit.listserv.db2-l
To: <[login to unmask email]>
Sent: Thursday, December 04, 2003 9:50 AM
Subject: Re: extract records from a file OS/390


> Can you just copy it to a file that you know is too small and it will
> truncate most of what you don't want anyway ?
>
>
>
> "Agarwal, Amit"
> <[login to unmask email] To:
> [login to unmask email]
> DPOORS.COM> cc:
> Sent by: "DB2 Data Base Subject: extract
> records from a file OS/390
> Discussion List"
> <[login to unmask email]>
> 12/04/2003 07:58 AM
> Please respond to "DB2
> Database Discussion list
> at IDUG"
>
>
>
>
> I have a large file, and unable to open in the edit mode.
> Can someone send me a sample JCL or REXX to extract 10 records from the
> file?
>
> Thanks
> Amit
>
> The information contained in this message is intended only for the
> recipient, and may be a confidential attorney-client communication or may
> otherwise be privileged and confidential and protected from disclosure. If
> the reader of this message is not the intended recipient, or an employee
or
> agent responsible for delivering this message to the intended recipient,
> please be aware that any dissemination or copying of this communication is
> strictly prohibited. If you have received this communication in error,
> please immediately notify us by replying to the message and deleting it
> from your computer.
> Thank you,
> Standard & Poor's
>
> --------------------------------------------------------------------------
-------
> Welcome to the IDUG DB2-L list. To unsubscribe, go to the archives and
> home page at http://www.idugdb2-l.org/archives/db2-l.html. From that page
> select "Join or Leave the list". If you will be out of the office, send
the
> SET DB2-L NO MAIL command to [login to unmask email] The IDUG List
> Admins can be reached at [login to unmask email] Find out the
> latest on IDUG conferences at http://conferences.idug.org/index.cfm
>
>
>
> **********
> The information contained in this communication is confidential, private,
> proprietary, or otherwise privileged and is intended only for the use of
the
> addressee. Unauthorized use, disclosure, distribution or copying is
strictly
> prohibited and may be unlawful. If you have received this communication
in
> error, please notify the sender immediately at (312)653-6000 in Illinois;
> (972)766-6900 in Texas; or (800)835-8699 in New Mexico.
> **********
>
> --------------------------------------------------------------------------
-------
> Welcome to the IDUG DB2-L list. To unsubscribe, go to the archives and
home page at http://www.idugdb2-l.org/archives/db2-l.html. From that page
select "Join or Leave the list". If you will be out of the office, send the
SET DB2-L NO MAIL command to [login to unmask email] The IDUG List
Admins can be reached at [login to unmask email] Find out the
latest on IDUG conferences at http://conferences.idug.org/index.cfm
>
>

---------------------------------------------------------------------------------
Welcome to the IDUG DB2-L list. To unsubscribe, go to the archives and home page at http://www.idugdb2-l.org/archives/db2-l.html. From that page select "Join or Leave the list". If you will be out of the office, send the SET DB2-L NO MAIL command to [login to unmask email] The IDUG List Admins can be reached at [login to unmask email] Find out the latest on IDUG conferences at http://conferences.idug.org/index.cfm