View previous topic :: View next topic
|
Author |
Message |
ragjeevan
New User
Joined: 06 Jun 2008 Posts: 5 Location: India
|
|
|
|
I have file with a packed decimal field of (7 P 2) length.How can i assign values into this field via CA Easytrieve®?
eg i want to move the value 123.45 into this field. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Quote: |
i want to move the value 123.45 into this field. |
This:
Code: |
DEFINE PKDFLD W 7 P 2 VALUE 0
.
.
PKDFLD = 123.45
DISPLAY PKDFLD
STOP
|
gives 123.45 |
|
Back to top |
|
|
ragjeevan
New User
Joined: 06 Jun 2008 Posts: 5 Location: India
|
|
|
|
Thanks for the prompt response.
COuld you please confirm whether the above piece of code will work if the PKDFLD column is in the output file intead of working storage? |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Yes, it should work in an output file as well. |
|
Back to top |
|
|
Deepthy Jose P
New User
Joined: 07 Mar 2007 Posts: 40 Location: India
|
|
|
|
Ragjeevan
Yes it works. I was able to assign value to a packed decimal filed in the output file. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Good to hear it - thanks for letting us know your code is working
d |
|
Back to top |
|
|
|