Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

How to check negative and positive values in a flat file

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

New User


Joined: 11 May 2007
Posts: 42
Location: bangalore

PostPosted: Fri May 18, 2007 10:41 pm    Post subject: How to check negative and positive values in a flat file
Reply with quote

The requirement is i have to count all the negative and positive values found for a particular field in a flat file.

The problem is this, the particular field is defined in my file as a packed decimal field, then how can i search for the -ve or +ve values in that.

Is there any method where i can put all the negative values in a separate file and all the positive values in a different file using DFSORT/SORT.
Back to top
View user's profile Send private message

William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3158
Location: Tucson AZ

PostPosted: Sat May 19, 2007 12:32 am    Post subject:
Reply with quote

You can have multiple OUTFIL records each with a different output and a different INCLUDE/OMIT condition.....
Back to top
View user's profile Send private message
dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Sat May 19, 2007 3:13 am    Post subject:
Reply with quote

Hello,

Please describe the output you want from this when it is working.
Back to top
View user's profile Send private message
Select-mf

New User


Joined: 11 May 2007
Posts: 42
Location: bangalore

PostPosted: Sat May 19, 2007 11:52 am    Post subject:
Reply with quote

Can you write its proper syntax, so that i can check in my system.
Back to top
View user's profile Send private message
William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3158
Location: Tucson AZ

PostPosted: Sat May 19, 2007 12:24 pm    Post subject:
Reply with quote

Do you need a pointer to a Sort Manual?
Back to top
View user's profile Send private message
Select-mf

New User


Joined: 11 May 2007
Posts: 42
Location: bangalore

PostPosted: Sat May 19, 2007 3:31 pm    Post subject:
Reply with quote

Hi,

I have tried the SYNCSORT and its working. I have divided the output in four files. In the file the two fields are starting from 100 and 107 respectively.

In SYSIN card, i have coded like

OUTFIL FILES=1,
INCLUDE=(100,7,PD,LT,0,AND,107,7,PD,LT,0)
OUTFIL FILES=2,
INCLUDE=(100,7,PD,GT,0,AND,107,7,PD,GT,0)
OUTFIL FILES=3,
INCLUDE=(100,7,PD,LT,0,AND,107,7,PD,GT,0)
OUTFIL FILES=4,
INCLUDE=(100,7,PD,GT,0,AND,107,7,PD,LT,0)
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 Copy RECFM =VB TO FB file with RECL =... sahil41352 DFSORT/ICETOOL 3 Wed Dec 28, 2016 11:29 pm
No new posts SQL query to run through list of valu... Ni3-db2 DB2 14 Wed Dec 14, 2016 9:52 am
No new posts Add PD field from 2nd file to PD in 1st Sushant Garje DFSORT/ICETOOL 6 Thu Dec 01, 2016 4:32 pm
No new posts File Aid to File Manager conversion murali3955 IBM Tools 4 Thu Nov 24, 2016 3:41 pm
No new posts What is the command to check MODE of ... rohanthengal CLIST & REXX 7 Fri Nov 18, 2016 1:48 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us