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
 

 

Is there any way to initialize a record with filler clause

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> Mainframe Interview Questions
View previous topic :: :: View next topic  
Author Message
Yuvaraj BP

New User


Joined: 12 Oct 2006
Posts: 12
Location: Bangalore

PostPosted: Sun Feb 04, 2007 10:16 pm    Post subject: Is there any way to initialize a record with filler clause
Reply with quote

Hai all,

Is there any way to nullify the entrapped data in the filler clause, I mean is there any way to initialize a record with filler clause so the the junk data entrapped in the filler cluase can also be nullified appropriately
Back to top
View user's profile Send private message

William Thompson

Global Moderator


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

PostPosted: Sun Feb 04, 2007 10:25 pm    Post subject: Re: Cobol programming
Reply with quote

Yuvaraj BP wrote:
Is there any way to nullify the entrapped data in the filler clause, I mean is there any way to initialize a record with filler clause so the the junk data entrapped in the filler cluase can also be nullified appropriately
"entrapped data"? are you referring to the the data in working storage represented by the elementary filler item?
In working storage, before populating the record, you can "initialize" the entire record by moving spaces to the group or using the INITIALIZE verb.
If the garbage already exists in a file record, that can be cleaned up also but it will require reading and then writing the record.
Back to top
View user's profile Send private message
Yuvaraj BP

New User


Joined: 12 Oct 2006
Posts: 12
Location: Bangalore

PostPosted: Sun Feb 04, 2007 10:36 pm    Post subject:
Reply with quote

the verb INITIALIZE did not clean the entrapped data in the filler clause, but i cleared only the data in the data declared under the group item.
Back to top
View user's profile Send private message
William Thompson

Global Moderator


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

PostPosted: Sun Feb 04, 2007 10:43 pm    Post subject:
Reply with quote

Yuvaraj BP wrote:
the verb INITIALIZE did not clean the entrapped data in the filler clause, but i cleared only the data in the data declared under the group item.
Yup, I should have looked it up first.... icon_redface.gif
If the filler is PIC X stuff, you could move spaces to the whole thing and then initialize it if you wanted named numeric fields set correctly.

Does that help?
Back to top
View user's profile Send private message
Yuvaraj BP

New User


Joined: 12 Oct 2006
Posts: 12
Location: Bangalore

PostPosted: Sun Feb 04, 2007 10:47 pm    Post subject:
Reply with quote

sorry to ask you, i did not get this particular segment of your suggestion

"if you wanted named numeric fields set correctly."
Back to top
View user's profile Send private message
William Thompson

Global Moderator


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

PostPosted: Sun Feb 04, 2007 10:51 pm    Post subject:
Reply with quote

Yuvaraj BP wrote:
sorry to ask you, i did not get this particular segment of your suggestion
"if you wanted named numeric fields set correctly."
That is the beauty if the INITIALIZE verb, chacter fields get filled with spaces while numeric fields, comp, comp3 and display, get zeros.
Back to top
View user's profile Send private message
Yuvaraj BP

New User


Joined: 12 Oct 2006
Posts: 12
Location: Bangalore

PostPosted: Sun Feb 04, 2007 10:55 pm    Post subject:
Reply with quote

so can i ask you again, how to initialize the filler clause variables, i am sorry because i could not follow that if you have answered in this thread.
Back to top
View user's profile Send private message
William Thompson

Global Moderator


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

PostPosted: Sun Feb 04, 2007 10:57 pm    Post subject:
Reply with quote

William Thompson wrote:
If the filler is PIC X stuff, you could move spaces to the whole thing.....
In other words, the overall group name....
Back to top
View user's profile Send private message
Yuvaraj BP

New User


Joined: 12 Oct 2006
Posts: 12
Location: Bangalore

PostPosted: Sun Feb 04, 2007 11:04 pm    Post subject:
Reply with quote

thank you,
i will try this, and again, i will meet you, bye
Back to top
View user's profile Send private message
mmwife

Super Moderator


Joined: 30 May 2003
Posts: 1592

PostPosted: Tue Feb 06, 2007 8:23 am    Post subject:
Reply with quote

Hi Yuvaraj,

The usual approach is to move spaces to the group level as Bill suggested, then INITIALIZE the group.
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 -> Mainframe Interview Questions All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts How to update a portion of text in a ... Bill Woodger DFSORT/ICETOOL 25 Wed Nov 09, 2016 9:41 pm
No new posts sort with previous record anatol DFSORT/ICETOOL 9 Thu Oct 06, 2016 2:36 am
No new posts Get Record count in summary record fo... Atul Banke DFSORT/ICETOOL 21 Fri Sep 23, 2016 4:17 pm
No new posts Change date (DD/MM/YY) in 2nd record ... uday kiran DFSORT/ICETOOL 12 Wed Sep 07, 2016 10:57 pm
No new posts Using 'parm' to vary SORTOUT record v... Sysaron DFSORT/ICETOOL 13 Wed Sep 07, 2016 9:24 pm


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