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
 

 

Can I compare the value of two fields of a file?

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> Compuware & Other Tools
View previous topic :: :: View next topic  
Author Message
poonam_madaan

New User


Joined: 01 Dec 2006
Posts: 3
Location: Bangalore

PostPosted: Fri Dec 01, 2006 2:03 pm    Post subject: Can I compare the value of two fields of a file?
Reply with quote

Can I compare the value of two fields of a file using file-aid?
For ex:
COL1=COL2 or 10:5 = 20: 5 (this is just an example where col1 is on position 10 and col2 in on position 20)
Back to top
View user's profile Send private message

MFRASHEED

Active User


Joined: 14 Jun 2005
Posts: 186
Location: USA

PostPosted: Fri Dec 01, 2006 11:26 pm    Post subject: Re: Can I compare the value of two fields of a file?
Reply with quote

Yes you can, on compare screen specify column offset , length and type:

Code:

File-AID ----------- Compare - Unformatted Criteria ---------------------
COMMAND ===>                                                 SCROLL ===>
      OLD                   NEW                                         
 Cmd  Pos.    Length Type   Pos.    Length Type   Status Display         
                                                                         
  _   1       133     C     1       133     C     COMPARISON FIELD       
  _   _____   _____   __    _____   _____   __                           
  _   _____   _____   __    _____   _____   __                           
  _   _____   _____   __    _____   _____   __                           
  _   _____   _____   __    _____   _____   __                           
  _   _____   _____   __    _____   _____   __                           
  _   _____   _____   __    _____   _____   __                           
  _   _____   _____   __    _____   _____   __                           
  _   _____   _____   __    _____   _____   __                           
  _   _____   _____   __    _____   _____   __                           
  _   _____   _____   __    _____   _____   __                           
  _   _____   _____   __    _____   _____   __                           
  _   _____   _____   __    _____   _____   __                           
  _   _____   _____   __    _____   _____   __                           
  _   _____   _____   __    _____   _____   __                           
  _   _____   _____   __    _____   _____   __                           
  _   _____   _____   __    _____   _____   __                           
  _   _____   _____   __    _____   _____   __                           
Cmd: S = Sync/Key, T = Tolerance, C = Compare, R = Reset       
         
Back to top
View user's profile Send private message
poonam_madaan

New User


Joined: 01 Dec 2006
Posts: 3
Location: Bangalore

PostPosted: Mon Dec 04, 2006 10:12 am    Post subject: Re: Can I compare the value of two fields of a file?
Reply with quote

Thanks MFRASHEED for the reply..
But How do I reach this screen. I'm giving option v;f;10..
but when I give the same name for Old and New file, it gives me error.
I'm using Compare Mode as U and selection usage criteria as T. It doesnt give me this screen. On the next screen I chose option 3 and it gives me the following screen:
AND
Cmd /OR Position Length RO Data Value
--- --- -------- ------ -- ----------------------------------------------------
___ _____ _____ EQ ____________________________________________________
___ AND _____ _____ EQ ____________________________________________________
___ AND _____ _____ EQ ____________________________________________________
___ AND _____ _____ EQ ____________________________________________________
___ AND _____ _____ EQ ____________________________________________________
___ AND _____ _____ EQ ____________________________________________________
___ AND _____ _____ EQ ____________________________________________________
___ AND _____ _____ EQ ____________________________________________________
___ AND _____ _____ EQ ____________________________________________________
___ AND _____ _____ EQ ____________________________________________________
___ AND _____ _____ EQ ____________________________________________________
___ AND _____ _____ EQ ____________________________________________________
___ AND _____ _____ EQ ____________________________________________________
___ AND _____ _____ EQ ____________________________________________________
Back to top
View user's profile Send private message
MFRASHEED

Active User


Joined: 14 Jun 2005
Posts: 186
Location: USA

PostPosted: Tue Dec 05, 2006 4:23 am    Post subject: Re: Can I compare the value of two fields of a file?
Reply with quote

If fields are in same file, just make copy of the file and use one as OLD and other as NEW.

You would use Selection criteria only if you want filter out records before compare, otherwise use 'N'.

Next screen will be 'Compare - Execution Options', choose online if file is small.

Next screen will be
Code:

 File-AID ----------------- Compare - Criteria Options -------------------------
 COMMAND ===>                                                                   
                                                                               
 Specify Initial Compare Options:                                               
                                                                               
  Compare type            ===> S   (S = Sorted/Keyed; R = ReadAhead; 1 = 1-to-1)
                                                                               
  Read-ahead record count ===>     (If type = R, specify read-ahead count)     
  Read-ahead sequence     ===> I   (E= Enforce; I = Ignore)                     
                                                                               
  Records to compare      ===> ALL (All or maximum number of records)           
  Differences to compare  ===> ALL (All or maximum number of differences)       
                                                                               
  Modify print defaults   ===> N   (Y = Yes; N = No)                           
  Specify output criteria ===> N   (Y = Yes; N = No)                           


and final screen will be 'Compare - Unformatted Criteria' as given earlier.
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 -> Compuware & Other Tools All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts SORTJOIN - Copy Matched and Unmatched... Steve Ironmonger DFSORT/ICETOOL 0 Tue Jan 17, 2017 4:26 pm
No new posts Storing huge volume of data, compare ... Pradeep K M All Other Mainframe Topics 3 Mon Jan 16, 2017 5:08 pm
No new posts Syncsort Help to group fields sudhakarraju SYNCSORT 6 Thu Dec 29, 2016 1:38 am
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 Add PD field from 2nd file to PD in 1st Sushant Garje DFSORT/ICETOOL 6 Thu Dec 01, 2016 4:32 pm


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