View previous topic :: View next topic
|
Author |
Message |
samarjeet singh
New User
Joined: 17 Jun 2011 Posts: 1 Location: india
|
|
|
|
1. We have a VSAM file A having following layout.
Org 9(3)
Acct X(19)
Name X(30)
Status X
Addr 1 X(30)
Addr 2 X(30)
State X(10)
Pin X(10)
Filler X(26)
Age 9(03)
DOB X(8)
We want to add 2 new fields in the file without changing the length of the file.
Loan Eligibility 9(17) Comp-3
Number of Years 9(02)
Where will you suggest to add these fields? What will be the new layout of the file? |
|
Back to top |
|
|
Dsingh29
Active User
Joined: 16 Dec 2008 Posts: 132 Location: IBM
|
|
|
|
Hi There,
Did you went through any Mainframe training ?
Fillers are meant for this purpose.
You could have asked any of your colleagues at work (would have taken you lesser time) instead of posting here on an year old thread. |
|
Back to top |
|
|
gudguy.deepak
New User
Joined: 29 Sep 2010 Posts: 3 Location: Hyderabad, India
|
|
|
|
Hi there,
Quote: |
Hi There,
Did you went through any Mainframe training ?
Fillers are meant for this purpose.
You could have asked any of your colleagues at work (would have taken you lesser time) instead of posting here on an year old thread.
|
thanks for guiding him. well what needs to be done when you are changing the layout permanently and getting it replaced with the newone.
The REDEFINE clause wont seem to work since there is a complete replacement of file layout.
Dsingh29, can you suggest a conversion Program for the above requisite. ? |
|
Back to top |
|
|
Dsingh29
Active User
Joined: 16 Dec 2008 Posts: 132 Location: IBM
|
|
|
|
Can you please elaborate on the purpose of this VSAM file? Is it being used for reading or for writing in the program. |
|
Back to top |
|
|
Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
|
|
samarjeet singh wrote: |
[...]
Filler X(26)
[...]
We want to add 2 new fields in the file without changing the length of the file.
Loan Eligibility 9(17) Comp-3
Number of Years 9(02)
Where will you suggest to add these fields? What will be the new layout of the file? |
Do you mean without changing the length of the record? One might go with the other, but seems an unusual way to say things.
Why do you need help from us to change your record layout? Is there no-one else in your organisation? You have a spec? Any colleagues? A boss?
It has already been pointed out to you where to make the change. Try to make a good job of it so that the size of the FILLER now is equal to size of new fields plus size of new FILLER. What do you have in a COMP-3 9(17) without a sign, without decimal places? What is the maximum sort of value you expect in the field? |
|
Back to top |
|
|
Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
|
|
gudguy.deepak wrote: |
[...]
... well what needs to be done when you are changing the layout permanently and getting it replaced with the newone.
The REDEFINE clause wont seem to work since there is a complete replacement of file layout.
[...] |
I have no idea what you are trying to say. It's Monday morning, so I'll leave it at that and wait until you've had tea-and-biscuits, opened your eyes and put your brain in gear.
Oh, it's only the morning here... |
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10889 Location: italy
|
|
|
|
it' s going to be a very long week |
|
Back to top |
|
|
gudguy.deepak
New User
Joined: 29 Sep 2010 Posts: 3 Location: Hyderabad, India
|
|
|
|
Quote: |
. We have a VSAM file A having following layout.
Org 9(3)
Acct X(19)
Name X(30)
Status X
Addr 1 X(30)
Addr 2 X(30)
State X(10)
Pin X(10)
Filler X(26)
Age 9(03)
DOB X(8)
We want to add 2 new fields in the file without changing the length of the file.
Loan Eligibility 9(17) Comp-3
Number of Years 9(02)
Where will you suggest to add these fields? What will be the new layout of the file?
_________________
samar singh |
Can anyone suggest a conversion program that will convert the existing file’s record to the new layout permanently, so that the new-layout can be used henceforth.
I have a similar problem of layout change, alongwith some additional functionality needed to be done :
The following consideration to be taken while coding
Age < 18 --> New fields will contain 0
Age >=18 and < 30 --> Loan Eligibility should be 30,000 and Number of Years should be 10
Age >=30 and < 50 --> Loan Eligibility should be 20,000 and Number of Years should be 07
Age >=50 and <= 70 --> Loan Eligibility should be 10,000 and Number of Years should be 03
Age > 70 --> New fields will contain 0 |
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10889 Location: italy
|
|
|
|
since you both see to work for the same organization, or taking the same class
why don 't you get together and do some some cooperative thinking instead of waiting to spoonfed on a forum !
also from the question content both of You seem to be better fit for the beginners forum here
ibmmainframeforum.com/ |
|
Back to top |
|
|
Dsingh29
Active User
Joined: 16 Dec 2008 Posts: 132 Location: IBM
|
|
|
|
deepak, instead of looking for code, you should start working on your code.
You didnt cared to answer:
Quote: |
Can you please elaborate on the purpose of this VSAM file? Is it being used for reading or for writing in the program. |
I think you are stuck with the term "conversion program", what purpose it will solve, I wonder. If you change the layout it will automatically used henceforth. |
|
Back to top |
|
|
gudguy.deepak
New User
Joined: 29 Sep 2010 Posts: 3 Location: Hyderabad, India
|
|
|
|
Thanks Dsingh29 for clarifying on " conversion-program " .
I was really stuck and confused on that part |
|
Back to top |
|
|
|