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
 

 

Checking for spaces or blanks in Cobol

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming
View previous topic :: :: View next topic  
Author Message
abhishek mitra

New User


Joined: 24 Feb 2008
Posts: 48
Location: Kolkata

PostPosted: Wed Mar 19, 2008 3:09 pm    Post subject: Checking for spaces or blanks in Cobol
Reply with quote

Hi,

I was trying to check for whether a value is coming spaces or blanks from the CICS screen. If it is coming spaces or blank I shall update NULL in table.
the field which catches the data in the CICS is Numeric and the field I use in the Cobol that is too Numeric.

Can anyone please help me to get the logic.
Back to top
View user's profile Send private message

dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6967
Location: porcelain throne

PostPosted: Wed Mar 19, 2008 3:56 pm    Post subject:
Reply with quote

after receiving the screen and interrogating the field, if the input screen field is <= spaces (BLANKS????? that is not a cobol term) then set the null-indicator for that column to -1, else move the value to the host variable used for the column in the insert command and set the null-indicator to zero.
Back to top
View user's profile Send private message
abhishek mitra

New User


Joined: 24 Feb 2008
Posts: 48
Location: Kolkata

PostPosted: Wed Mar 19, 2008 4:22 pm    Post subject:
Reply with quote

dbzTHEdinosauer wrote:
after receiving the screen and interrogating the field, if the input screen field is <= spaces (BLANKS????? that is not a cobol term) then set the null-indicator for that column to -1, else move the value to the host variable used for the column in the insert command and set the null-indicator to zero.


Hi,
thanks for your reply. By blanks I did mean that in the CICS screen the field has not been entered at all. It has been left vacant. How d i check for that?
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10256
Location: italy

PostPosted: Wed Mar 19, 2008 4:33 pm    Post subject: Reply to: Checking for spaces or blanks in Cobol
Reply with quote

I do not remember the name of the mask but in this case the usual
procedure is to chek if the MDT is on
MDT = modified data tag
Back to top
View user's profile Send private message
UmeySan

Active Member


Joined: 22 Aug 2006
Posts: 755
Location: Germany

PostPosted: Wed Mar 19, 2008 4:59 pm    Post subject:
Reply with quote

What is MDT ?

A Bit in the attribute byte indicating modification of field on screen.If the user keys in any data into the field, it turns the MDT ON indicating that the data is modified. To save transmission time , 3270 terminal sends a field over the TC line only if the MDT is on. Otherwise, the field value is not transmitted.

More informations on BMS & good overview:
http://publib.boulder.ibm.com/infocenter/txformp/v6r0m0/index.jsp?topic=/com.ibm.cics.te.doc/erziah0035.htm

Regards, UmeySan
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 -> COBOL Programming All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
This topic is locked: you cannot edit posts or make replies. Cobol GUI (like Editor) Kala Mainframe COBOL Programming 14 Wed May 10, 2017 12:30 pm
No new posts IMS T-Pipe queue counts in a COBOL Pr... Siva NKK Kothamasu IMS DB/DC 0 Tue May 09, 2017 6:31 pm
No new posts COBOL Code Parsers and Lineage Establ... balimanja COBOL Programming 2 Tue May 02, 2017 3:30 am
No new posts Cobol upgrade - source code missing f... gthmrj IBM Tools 1 Wed Apr 26, 2017 6:04 pm
No new posts COBOL Programming Sandpit? jodrisco COBOL Programming 6 Wed Apr 12, 2017 3:47 am


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