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
 

 

GEtting Non numeric field value coming in numeric variable

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

Active User


Joined: 14 Jul 2005
Posts: 105

PostPosted: Fri Jan 16, 2009 9:52 pm    Post subject: GEtting Non numeric field value coming in numeric variable
Reply with quote

Dear Experts,
Before posting did I searched for around 1 hour in the forum but didnt got anything which could give the solution to my question.

I came across a situation where I have got a flat file in of lenght 100.There is fiels defined as packed decimal of lenght 4 which start at position 23 of the file.

Today date file in system is having non numberic value in some/or one of the reocrds in this file and before uploading this file into production for an emer fix I need to remove this records.

I tried to get these records from fileaid with searching with quick option for anything NE 0 option but it didnt reported anything for me.
The program is not capable enough of handling this situation in production as I said I am working on an emer fix to avoid the problem in tonight's run.


I hope I am clear and I am posting my question and right forumrequest you to please post a quick step to do this,thanks
Back to top
View user's profile Send private message

Arun Raj

Moderator


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

PostPosted: Fri Jan 16, 2009 10:32 pm    Post subject:
Reply with quote

raghavmcs,

Below are a few related topics which I got in less than 5 mins.

http://ibmmainframes.com/viewtopic.php?t=29815&highlight=eq+num
http://ibmmainframes.com/viewtopic.php?t=28477&highlight=eq+num
http://ibmmainframes.com/viewtopic.php?t=26505&highlight=eq+num
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: Fri Jan 16, 2009 10:37 pm    Post subject:
Reply with quote

raghavmcs,

I don't understand why you would expect a check for NE 0 to find non-numeric values.

Here's a DFSORT job that will remove records that have a non-numeric PD value in positions 23-26.

Code:

//S1    EXEC  PGM=ICEMAN
//SYSOUT    DD  SYSOUT=*
//SORTIN DD DSN=...  input file
//SORTOUT DD DSN=...  output file
//SYSIN    DD    *
   OPTION COPY
   OMIT COND=(23,4,PD,NE,NUM)
/*


If it doesn't do what you want, then you need to give more details about what these non-numeric values look like - show some examples of these values in hex. Also give the RECFM and LRECL of your input file.
Back to top
View user's profile Send private message
raghavmcs

Active User


Joined: 14 Jul 2005
Posts: 105

PostPosted: Fri Jan 16, 2009 11:03 pm    Post subject:
Reply with quote

Experts thanks for all your replies and suggestions..

Frank appreciate your solution I was not knowing that DFSORT was having NUMERIC check option also,my bad...

we were able to recover the correct file whicih is going to get uploaded in tonights run.The recovered file was having all the correct data.

Frank,
Still I ran your solution with the file I was having with me and it gave the desired results by skiping the bad records,thanks
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 INVALID FIELD OR CONSTANT IN SORTOF ?? Ron Klop DFSORT/ICETOOL 8 Wed Jan 11, 2017 3:44 pm
No new posts Performing arithmetic on input field zh_lad DFSORT/ICETOOL 31 Tue Dec 06, 2016 8:04 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
No new posts How to split the records using the am... vnktrrd DFSORT/ICETOOL 24 Fri Oct 28, 2016 7:33 pm
No new posts Sort records based on numeric field. Alks SYNCSORT 2 Wed Oct 19, 2016 10:14 pm


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