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
 

 

Hard code a date value in a comp3 column of a file

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

New User


Joined: 09 Jan 2007
Posts: 17
Location: india

PostPosted: Fri Apr 20, 2007 2:38 am    Post subject: Hard code a date value in a comp3 column of a file
Reply with quote

Hi all,

I need to hard code a date value in a comp3 column of a file.
PIC 9(05) COMP-3

i did a 'hex on' and put the values '04111C' : (for 2004 and day 111)
It is abending with soc7. and i found out that the problem is with this date value i hard coded. i dont know if i have entered correct data in correct format. kindly help.

i file manager it look like below:

Code:
SRV-DT-OF-SERV-L-312(1)
                    #15
                PD 66:3
                 <---+>
                       
                   4111
                    011
                    41C
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: Fri Apr 20, 2007 3:01 am    Post subject:
Reply with quote

Hello,

What is abending? The sort or some other program trying to use the file?

Please post the jcl and control statements from the abended run as well as the error output.

Also, please post more of the data record in hex (using the "Code" tab at the top of the reply panel for readability).

This
Quote:

<---+>

4111
011
41C
has me a bit confused. What is the 4111 line - it isn't part of the comp-3 field, right? The 3 bytes of over/under look valid for a 5-digit packed-decimal value.

We're here when you post more info.
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 Apr 20, 2007 4:32 am    Post subject:
Reply with quote

raj,

It's unclear what you're doing or even what program or language you're using.

If you want to insert a P'04111' value with DFSORT, you can do it in a BUILD parameter in a couple of ways. Examples:

Code:

   INREC BUILD=(...,X'04111C',...)


or

Code:

  INREC BUILD=(...,+4111,TO=PD,LENGTH=3,...)


If that doesn't help, then you need to explain more clearly what you want to do.
Back to top
View user's profile Send private message
prasadvrk

Active User


Joined: 31 May 2006
Posts: 200
Location: Netherlands

PostPosted: Fri Apr 20, 2007 1:59 pm    Post subject:
Reply with quote

It may be abending due to some other reason. First ascertain whether the format of the data you are supplying is correct. Are you sure it expects 04 for year and 111 for the number of the day,
Back to top
View user's profile Send private message
raja1128

New User


Joined: 09 Jan 2007
Posts: 17
Location: india

PostPosted: Fri Apr 20, 2007 11:08 pm    Post subject: Re: HARD CODING A COMP3 VALUE IN A FILE
Reply with quote

hi all,

4111
011
41C


First line is just what we see when hex is off.
Actually soc7 was due to a empty file going to next step from the step which takes my file as input. it is not a sort. icon_question.gif
i fixed it.
thank you all for support.

any ways, i am not sure if i had hard coded the s9(5) comp3 value correctly.
is my procedure correct?

regards.
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: Fri Apr 20, 2007 11:46 pm    Post subject:
Reply with quote

Hello,

Good to hear the problem is fixed icon_smile.gif

Yes, the way you manually created the comp-3 data will work for the field you described.
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 Extra character appears in file when ... Balu5491 All Other Mainframe Topics 1 Wed Jul 26, 2017 2:39 pm
No new posts SSH - known_hosts file configuration vasanthz All Other Mainframe Topics 2 Wed Jul 26, 2017 2:10 am
This topic is locked: you cannot edit posts or make replies. Fetching data from BAI File arunsoods JCL & VSAM 1 Wed Jul 19, 2017 4:28 pm
No new posts Write out NODUPS but just from one file Jay Villaverde DFSORT/ICETOOL 8 Fri Jul 14, 2017 12:44 am
No new posts Loading data to table gives wrong for... Raghu navaikulam DB2 19 Thu Jul 13, 2017 2:11 pm


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