Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
DFSORT OMIT for COMP-3

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL
View previous topic :: :: View next topic  
Author Message
Shivashankar Biradar

New User


Joined: 07 Jul 2008
Posts: 2
Location: Pune

PostPosted: Tue Jul 22, 2008 12:35 pm    Post subject: DFSORT OMIT for COMP-3
Reply with quote

Hi,

Please let me know the syntax for omit a record depending on the comp-3 value using DFSORT/ICETOOL.

Thanks,
Shivashankar
Back to top
View user's profile Send private message

karthikr44

Active User


Joined: 25 Aug 2007
Posts: 235
Location: Chennai

PostPosted: Tue Jul 22, 2008 12:45 pm    Post subject: Reply to: DFSORT OMIT for COMP-3
Reply with quote

HI,

It is very simple.
Just use the sort card

Code:

   OMIT COND=(24,3,PD,EQ,NUM)


Records will be omitted from the application if the first field (byte 24 to byte 26) is identified as packed decimal numeric.

regards
R KARTHIK
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Moderator


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

PostPosted: Tue Jul 22, 2008 9:36 pm    Post subject:
Reply with quote

Shivashankar,

Assuming you want to check a PD field for a particular value, the general format for the DFSORT control statements would be:

Code:

   OPTION COPY
   OMIT COND=(p,m,PD,op,value)


p is the starting position of the PD field. m is the length of the PD field. op is the comparison operator (EQ, NE, LT, LE, GT, GE) and value is a decimal number (n, +n, -n). So for example, if you wanted to OMIT records with a 2-byte PD value in positions 21-22 equal to +12, you would use:

Code:

    OPTION COPY
    OMIT COND=(21,2,PD,EQ,+12)


If you need more specific help, explain in more detail what you want to do.

If you're not familiar with DFSORT and DFSORT's ICETOOL, I'd suggest reading through "z/OS DFSORT: Getting Started". It's an excellent tutorial, with lots of examples, that will show you how to use DFSORT, DFSORT's ICETOOL and DFSORT Symbols. You can access it online, along with all of the other DFSORT books, from:

www.ibm.com/servers/storage/support/software/sort/mvs/srtmpub.html
Back to top
View user's profile Send private message
Shivashankar Biradar

New User


Joined: 07 Jul 2008
Posts: 2
Location: Pune

PostPosted: Wed Jul 23, 2008 4:08 pm    Post subject: Reply to: DFSORT OMIT for COMP-3
Reply with quote

Sorry, forgot to mention info about the field and file.

Actually that field is defined as PIC S9(03) COMP-3 and in the VB file. It is the first field in the file.
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Moderator


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

PostPosted: Wed Jul 23, 2008 9:14 pm    Post subject:
Reply with quote

Since it's a VB file, the first field in the file starts at position 5 after the RDW. PIC S9(03) COMP-3 is a 2-byte PD value. So use 5 for p and 2 for m in the OMIT statement as shown in my previous post.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Need urgent suggestion on DFSORT subratarec DFSORT/ICETOOL 6 Wed Mar 21, 2018 8:46 pm
No new posts COMP Variables Mismatch gayu7 COBOL Programming 5 Wed Dec 20, 2017 5:06 pm
No new posts Moving a COMP-3 Variable to a Numeric... ajayachander COBOL Programming 2 Thu Dec 14, 2017 5:46 pm
No new posts Formatting using DFsort Guru Nandu DFSORT/ICETOOL 5 Thu Nov 30, 2017 7:33 am
No new posts Compare VSAM files using DFSORT pshongal DFSORT/ICETOOL 5 Thu Nov 23, 2017 10:24 am

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us