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
 

 

Partly move spaces into a Map variable

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CICS
View previous topic :: :: View next topic  
Author Message
dudenithy

New User


Joined: 02 Mar 2012
Posts: 48
Location: India

PostPosted: Mon Sep 17, 2012 6:23 pm    Post subject: Partly move spaces into a Map variable
Reply with quote

Hi,

I have a existing screen with lines displaying as below,

L=LOST VALID CODES ARE VALID CODES ( )
S=STOLEN 04=PICK UP ARE 0-9 AND
( )
F=FRAUD 07=SPCL PICK UP A-F AND ( )


I have the variable declared for the above as,

000287 SG11070 DFHMDF POS=(10,70), X
000288 LENGTH=01, X
000289 ATTRB=(ASKIP,NORM), X
000290 INITIAL=')'
000291 ***********************************************************************
000292 DFHMDF POS=(11,01), X
000293 LENGTH=08, X
000294 ATTRB=(ASKIP,NORM), X
000295 INITIAL='S=STOLEN'
000296 ***********************************************************************
000297 DFHMDF POS=(11,28), X
000298 LENGTH=12, X
000299 ATTRB=(ASKIP,NORM), X
000300 INITIAL='04=PICK UP'

000301 ***********************************************************************
000302 DFHMDF POS=(11,54), X
000303 LENGTH=11, X
000304 ATTRB=(ASKIP,NORM), X
000305 INITIAL='ARE 0-9 AND'
000306 ***********************************************************************
000307 SG11166 DFHMDF POS=(11,66), X
000308 LENGTH=01, X
000309 ATTRB=(ASKIP,NORM), X
000310 INITIAL='('


My requirement is I need to hide '04=PICK UP' string from display in map. Is there any option to hide that string alone through CICS program. Since the variable is declared for all continuous strings in the physical map, is there any option to hide specific strings, like using Cobol reference modification.
Back to top
View user's profile Send private message

Rohit Umarjikar

Senior Member


Joined: 21 Sep 2010
Posts: 1610
Location: NY,USA

PostPosted: Mon Sep 17, 2012 7:00 pm    Post subject:
Reply with quote

1) If its one time change i.e. in future you don't need that to be displayed then why don't you change the map with DRK attrb.
2) if that is to be controlled dynamically then add a lable to it and then move DRK attribute to 'A' byte of it and send the map.

I might not be knowing other options but this what I can think of it.
Back to top
View user's profile Send private message
dudenithy

New User


Joined: 02 Mar 2012
Posts: 48
Location: India

PostPosted: Mon Sep 17, 2012 7:40 pm    Post subject:
Reply with quote

Thanks Rogit for ur reply.

Yeah, this is my earlier thought too (to modify map with declaring a variable for that string with DRK attribute). But I was thinking not to change the Map definition, but just to change the CICS Program to partly move spaces into that String position, so that recompilation of pgm is enough. I dont find any option like Reference modification in cobol.
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 1715
Location: UK

PostPosted: Tue Sep 18, 2012 1:07 am    Post subject:
Reply with quote

Quote:
I dont find any option like Reference modification in coboll

Reference modification IS a COBOL term. for a similar function in other language the term is SUBSTR or sub-string. So I do not undertand what you are saying.
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 7913
Location: Bellevue, IA

PostPosted: Tue Sep 18, 2012 1:15 am    Post subject:
Reply with quote

There is a link to Manuals at the top of this page. Click on it, find the Enterprise COBOL Language Reference manual, and read section 1.8.1.10 Reference Modification to learn more. Reference modifcation has been part of COBOL since at least 1993, and most likely longer, so there is no excuse for you not knowing what it is and how it works. Unless, of course, you do not know COBOL at all.
Back to top
View user's profile Send private message
Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7230

PostPosted: Tue Sep 18, 2012 3:07 am    Post subject:
Reply with quote

Quote:
But I was thinking not to change the Map definition, but just to change the CICS Program to partly move spaces into that String position, so that recompilation of pgm is enough. I dont find any option like Reference modification in cobol.


In <whatever it is that I'm calling the CICS Program> I'd like to use some sort of "substring" processing. I can't find in <whatever language the CICS Program is written in> any processing which seems to me to be the equivalent of reference-modification in Cobol, which I know about and use all the time <because it is so much less typing than having to define proper data, and I never have to maintain any programs, just write new ones>.

That's how I read it anyway.
Back to top
View user's profile Send private message
Bill O'Boyle

CICS Moderator


Joined: 14 Jan 2008
Posts: 2502
Location: Atlanta, Georgia, USA

PostPosted: Tue Sep 18, 2012 6:01 am    Post subject: Reply to: Partly move spaces into a Map variable
Reply with quote

You'll need to add a label to line 297, preceding the DFHMDF macro, such as SG11128 and re-assemble the map, then re-compile the program. Be careful of redefined map-copybooks in the program, because yours just changed and it will acquire adjustments.

In the generated map-copybook, look for map-field SG11128A (attribute-byte field), move DFHBMDAS to it and you've darkened the literal "'04=PICK UP'".

IBM byte-attributes can be found in copybook DFHBMSCA, in the SDFHMAC library.

Remember, in BMS/Assembler icon_arrow.gif NO LABEL, NO ACCESS. Thank you for your support.... icon_smile.gif
Back to top
View user's profile Send private message
dudenithy

New User


Joined: 02 Mar 2012
Posts: 48
Location: India

PostPosted: Tue Sep 18, 2012 12:17 pm    Post subject:
Reply with quote

Thanks Bill for your suggestion.

Nic,Robert, I'm aware of Reference modfication in Cobol and using it for a long time. I intended to said that i couldn't find similar kind of function in CICS command, for my current problem. (moving spaces to part of a whole string). Thanks anyway for your responses icon_smile.gif
Back to top
View user's profile Send private message
Rohit Umarjikar

Senior Member


Joined: 21 Sep 2010
Posts: 1610
Location: NY,USA

PostPosted: Tue Sep 18, 2012 12:33 pm    Post subject:
Reply with quote

Dudenithy,

Whatever Me and Bill suggested , why don't you try out that part?

Is changing of map is the concern also what logic are you thinking about Reference modification in sense with your question?
Back to top
View user's profile Send private message
dudenithy

New User


Joined: 02 Mar 2012
Posts: 48
Location: India

PostPosted: Tue Sep 18, 2012 12:44 pm    Post subject:
Reply with quote

Yes Rohit, Atlast i need to change the map on no other option. I have raised this post to get an idea of any functionality that ll do partial space move to the cics variable. Reference Modification came into picture because in a cobol program, by using this, we ll move partial space move to a variable. If any option is available, i can just change Cics program alone and not map.
Back to top
View user's profile Send private message
Rohit Umarjikar

Senior Member


Joined: 21 Sep 2010
Posts: 1610
Location: NY,USA

PostPosted: Tue Sep 18, 2012 12:49 pm    Post subject:
Reply with quote

Quote:
Remember, in BMS/Assembler NO LABEL, NO ACCESS. Thank you for your support....
Back to top
View user's profile Send private message
dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Tue Sep 18, 2012 11:51 pm    Post subject:
Reply with quote

Hello,

Quote:
Remember, in BMS/Assembler NO LABEL, NO ACCESS. Thank you for your support....
Well Kinda . . . Possibly there is something i misunderstand.

Reference Modification is nothing more than an assembler move with the code specifying the "from" and "to" memory locations and length in the instruction rather than having the assembly determine from the datatype of the "field".

As i mentioned, i may misunderstand something relevant to thei particular question, but all of us who wrote any kind of generic code did this for many, many years.
Back to top
View user's profile Send private message
Bill O'Boyle

CICS Moderator


Joined: 14 Jan 2008
Posts: 2502
Location: Atlanta, Georgia, USA

PostPosted: Wed Sep 19, 2012 3:08 am    Post subject: Reply to: Partly move spaces into a Map variable
Reply with quote

Dick,

Without a label defined to this map-location in the MAPSET, you would have to update the load-module plus, you'd need to know the offset.

Updating the load-module would be a very bad idea. This is why I had suggested to add a label and set the label/field attribute-byte in the generated map-copybook (SG11128A) to ASKIP,DRK (DFHBMDAS).
Back to top
View user's profile Send private message
dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Wed Sep 19, 2012 3:22 am    Post subject: Reply to: Partly move spaces into a Map variable
Reply with quote

Thanks Bill,

My bad - was having a brain fade . . . icon_redface.gif

I'd forgotten the target was actually the map. Had the data been build in a ds, might have been better. When slinging code was my main "thing to do", i worked in "temproray fields" rather than within the files, database areas, maps etc. (edited for clarity)

As i said - "Possibly there is something i misunderstand." D'oH .
(quietly skulking away from the terminal . . .)


d
Back to top
View user's profile Send private message
Rohit Umarjikar

Senior Member


Joined: 21 Sep 2010
Posts: 1610
Location: NY,USA

PostPosted: Thu Sep 20, 2012 2:59 pm    Post subject:
Reply with quote

Dick,

We just wanted to convey TS that Reference modification in this perticulat case is not possible. icon_smile.gif
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 -> CICS 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. How to move a long alphanumeric data ... lind sh COBOL Programming 8 Mon Dec 05, 2016 7:51 pm
No new posts Protection Exception while move 0 to ... Kevin Vaz CICS 10 Tue Oct 18, 2016 4:19 pm
No new posts To trim spaces in a pipe delimited da... Nish84 COBOL Programming 16 Mon Oct 10, 2016 1:54 pm
No new posts Format to pipe delimited with variabl... pshongal SYNCSORT 6 Wed Sep 14, 2016 2:48 pm
No new posts Removing Extra Spaces in a comma sepa... Puspojit DFSORT/ICETOOL 3 Tue Sep 13, 2016 7:46 am


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