View previous topic :: View next topic
|
Author |
Message |
vishabus
New User
Joined: 25 Oct 2006 Posts: 24 Location: India
|
|
|
|
Hi,
In easytrieve what is the difference between using "MOVE" and using "=" sign. We have a piece of code where in we are using "MOVE" statement to move a value to the RETURN-CODE.
MOVE 1 TO RETURN-CODE
The easytrieve instead of ending with return code of 1 is ending with a RC of 64. When I do the display of RETURN-CODE, the SYSPRINT shows me the following value:
RETURN-CODE = 247447488.
However when I use the assignment operator, i.e., RETURN-CODE = 1, things work out fine.
Then as part of testing I moved 1 to a test variable defined as 9 N. The value which I see in sysprint is
WS-TEST = 100000000
Can somebody explain what exactly MOVE does in easytrieve.
I tried looking through various topics and couldn't locate any topic which might help me in this.
Thanks a ton !!! |
|
Back to top |
|
|
ksk
Active User
Joined: 08 Jun 2006 Posts: 355 Location: New York
|
|
|
|
Hi,
I have used MOVE statement in Ezetreive as used in COBOL. I used the following satatement in my Ezetreive program.
MOVE 'D' TO FLAG-IND
This statement moved D into FLAG-IND variable. Worked like COBOL MOVE statement. |
|
Back to top |
|
|
Rajesh Sampath
New User
Joined: 18 Jun 2008 Posts: 9 Location: Pune
|
|
|
|
Hi vishabus
From my knowledge
Move statement is using to move the value to the variable from LHS(Left hand side) to RHS (Right hand side).
But (=) equal to statement is using to move the value to the variable from RHS(Right hand side) to LHS(Left hand side).
Its the Major Difference between both.
Please correct me, If im wrong..
With Regards
Rajesh Sampath |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello vishabus,
Which version of easytrieve is used on your system? |
|
Back to top |
|
|
|