IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

dynamic changing PROT to UNPROT


IBM Mainframe Forums -> Mainframe Interview Questions
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
ravikumarreddy
Warnings : 1

New User


Joined: 29 Jul 2005
Posts: 23

PostPosted: Tue Sep 13, 2005 3:19 pm
Reply with quote

HI,

here my requirement is ...... i want to change the PROTECTED FIELDS TO UNPROTECTED FIELDS of map,that to on DYNAMICALLY...

THANKS IN ADVANCE,
ravi
Back to top
View user's profile Send private message
prakash271082

New User


Joined: 09 Sep 2005
Posts: 53

PostPosted: Tue Sep 13, 2005 3:53 pm
Reply with quote

Hi Ravi,
You Could use Attribute Check Byte to dynamically change from protected to unprotected and vicsversa etc.
For Eg:
Say in Your Map definition, your label for the field for which value to be received is XXX1. Then you could use
"MOVE DFHBMUNP TO XXX1A" => this will change that receiving field from Protected to Unprotected.
Hope this helps.
Back to top
View user's profile Send private message
radhakrishnan82

Active User


Joined: 31 Mar 2005
Posts: 435
Location: chennai, India

PostPosted: Tue Sep 13, 2005 3:58 pm
Reply with quote

ravi,

Lets take this case:

After performing some condition if you need to protect the values of field 'AAA' from editing,you can do the following:

Code:
If Action-performed = true
Move PRO to AAA-F  (defined in map)
else
Move UNP tO AAA-F
end-if


PRO and UNP are predefined field attributes.

Are you using this predefined attrbt in your shop?
Unless let me know,I can provide the values for these attributes.

hope this helps.
Back to top
View user's profile Send private message
radhakrishnan82

Active User


Joined: 31 Mar 2005
Posts: 435
Location: chennai, India

PostPosted: Tue Sep 13, 2005 4:10 pm
Reply with quote

DFHBMUNP can also be used.

You can also define datanames on your own and set these below values for such operation.

For unprotecting
Code:
MOVE UNP to AAA-F

else you declare some variable and assign the values to it.
Code:
UNPROTECT-MNO    PIC X VALUE ' '
................
 MOVE UNPROTECT to AAA-F.


Code:
01  IBM-FIELD-ATTRIBUTES.                               
  05  SET-CSR                   PIC S9(4) COMP VALUE -1.
  05  ERASE-EOF-ON              PIC X VALUE '?'.       
  05  UNP                       PIC X VALUE ' '.       
  05  UNP-MDT                   PIC X VALUE 'A'.       
  05  UNP-BRI                   PIC X VALUE 'H'.       
  05  UNP-BRI-MDT               PIC X VALUE 'I'.       
  05  UNP-DRK                   PIC X VALUE '<'.       
  05  UNP-DRK-MDT               PIC X VALUE '('.       
  05  UNP-NUM                   PIC X VALUE '&'.       
  05  UNP-NUM-MDT               PIC X VALUE 'J'.       
  05  UNP-NUM-BRI               PIC X VALUE 'Q'.       
  05  UNP-NUM-BRI-MDT           PIC X VALUE 'R'.       
  05  UNP-NUM-DRK               PIC X VALUE '*'.       
  05  UNP-NUM-DRK-MDT           PIC X VALUE ')'.       
  05  PRO                       PIC X VALUE '-'.       
  05  PRO-MDT                   PIC X VALUE '/'.       
  05  PRO-BRI                   PIC X VALUE 'Y'.       
  05  PRO-BRI-MDT               PIC X VALUE 'Z'.       
  05  PRO-DRK                   PIC X VALUE '%'.       
  05  PRO-DRK-MDT               PIC X VALUE '_'.       
  05  PRO-SKP                   PIC X VALUE '0'.       
  05  PRO-SKP-MDT               PIC X VALUE '1'.       
  05  PRO-SKP-BRI               PIC X VALUE '8'.       
  05  PRO-SKP-BRI-MDT           PIC X VALUE '9'.       
  05  PRO-SKP-DRK               PIC X VALUE '@'.       
  05  PRO-SKP-DRK-MDT           PIC X VALUE ''''
.

hope this helps.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> Mainframe Interview Questions

 


Similar Topics
Topic Forum Replies
No new posts Using Dynamic file handler in the Fil... COBOL Programming 2
No new posts changing defaults in db2 admin - Unlo... DB2 0
No new posts JCL Dynamic System Symbols JCL & VSAM 3
No new posts Synctool-dynamic split job for varyin... JCL & VSAM 7
No new posts Dynamic file allocation using JCL JCL & VSAM 8
Search our Forums:

Back to Top