View previous topic :: View next topic
|
Author |
Message |
ajay_diaz Warnings : 1 New User
Joined: 12 Sep 2005 Posts: 28
|
|
|
|
Can I simply check if length of the field on the BMS map is equal to 0 for checking if a field was modified?
I think YES, but I read somewhere that "No, not if ERASE EOF was used."
Can somebody please help? |
|
Back to top |
|
|
William Thompson
Global Moderator
Joined: 18 Nov 2006 Posts: 3156 Location: Tucson AZ
|
|
|
|
I'm sorry that I can't recall, but I know that you can "play" with the map interactivly with CECI...Try various inputs and see what information gets returned.... |
|
Back to top |
|
|
Mickeydusaor
Active User
Joined: 24 May 2006 Posts: 258 Location: Salem, Oregon
|
|
|
|
If you are going to check the length field then check for a X'80' |
|
Back to top |
|
|
Earl
Active User
Joined: 17 Jun 2007 Posts: 148 Location: oklahoma
|
|
|
|
If the ERASE EOF is depressed in the 1st position of the field the x'80'
will be in fieldnameF and fieldnameL will be ZERO. |
|
Back to top |
|
|
Mickeydusaor
Active User
Joined: 24 May 2006 Posts: 258 Location: Salem, Oregon
|
|
|
|
02 FILLER PIC X(12).
02 SYSDATEL COMP PIC S9(4).
02 SYSDATEF PICTURE X.
02 FILLER REDEFINES SYSDATEF.
03 SYSDATEA PICTURE X.
02 FILLER PICTURE X(2).
02 SYSDATEI PIC X(10).
the SYSDATEL field will have x'0000' and the
SYSDATEF will have the attribute for the field
when you use the EOL, which tells you that the
field has not been modified.
If you check the length field for the X'80'
this shows you that the FIELD has been
modified as for the question you asked. |
|
Back to top |
|
|
Earl
Active User
Joined: 17 Jun 2007 Posts: 148 Location: oklahoma
|
|
|
|
Mickeydusaor,
hmmm, maybe CICS has changed since last time I coded for this condition. I used to check fieldnameF (SYSDATEF) for the X'80' to detect eraseEOF keystroke. Which would mean field was modified, contained data, then erased.
in your example, SYSDATEL is the length field , so I really don't understand why CICS would post the x'80' in it. Its a 2byte field, so which byte contains the x'80' ? |
|
Back to top |
|
|
William Thompson
Global Moderator
Joined: 18 Nov 2006 Posts: 3156 Location: Tucson AZ
|
|
|
|
Mickeydusaor wrote: |
the SYSDATEL field will have x'0000' and the
SYSDATEF will have the attribute for the field
when you use the EOL, which tells you that the
field has not been modified.
If you check the length field for the X'80'
this shows you that the FIELD has been
modified as for the question you asked. |
I'm (was) fairly connected with CICS, but I've never really learned the "rules" for BMS fields back from the user.....Thanks for the insight.... |
|
Back to top |
|
|
Mickeydusaor
Active User
Joined: 24 May 2006 Posts: 258 Location: Salem, Oregon
|
|
|
|
If you really want to know if a field has been MODIFIED, either by the
user SPACING out the field or with the EOL key or typing in a new value
I check the field with what was originally sent to the screen and if they do not match, I move the new value to the original field that was saved. Using the LENGTH field to determine if the field has been modifed is not
really the correct way for processing the data on the MAP as I think you
have found out. |
|
Back to top |
|
|
Earl
Active User
Joined: 17 Jun 2007 Posts: 148 Location: oklahoma
|
|
|
|
Agreed, I prefer matching what was sent to received, but I've maintained a lot of code that check length fields. |
|
Back to top |
|
|
William Thompson
Global Moderator
Joined: 18 Nov 2006 Posts: 3156 Location: Tucson AZ
|
|
|
|
"as I think you have found out"
Right, ya' got it....
I just have never been required (by myself) to put a set of rules to it..... All things come to those that wait...
Thanks again... |
|
Back to top |
|
|
Mickeydusaor
Active User
Joined: 24 May 2006 Posts: 258 Location: Salem, Oregon
|
|
|
|
Yes, I have written and maintaned old and I mean old code,
back in the day this was the only way to know if the field
had been changed, but with the commarea to say and
return you data it made is much simpler to know when
a changed occurred. |
|
Back to top |
|
|
William Thompson
Global Moderator
Joined: 18 Nov 2006 Posts: 3156 Location: Tucson AZ
|
|
|
|
Macro level? BMS without SDF? Assembler coding the CSECT field structure and DSECT values in a straight output to a screen? |
|
Back to top |
|
|
Earl
Active User
Joined: 17 Jun 2007 Posts: 148 Location: oklahoma
|
|
|
|
ahhh ,,
music to my ears,
Macro Level, Assembler CICS , NO BMS
just 3270 native mode sends/receives
ST TIOABAR,TCTTEDA
DFHTC TYPE=SEND
those were the days |
|
Back to top |
|
|
Mickeydusaor
Active User
Joined: 24 May 2006 Posts: 258 Location: Salem, Oregon
|
|
|
|
Earl,
Bringing back old memories, ya but I do enjoy not having to remember
all of this, just getting older I quess. one thing I do miss is not having
access to some of the control blocks. |
|
Back to top |
|
|
|