Over half of the system variable symbols have local scope and therefore are not available in open code.
1 macro
2 getlocalsys
3 .* Define globals for values of interest
4 Gblc &clock,&location,&dsname,&nest
5 Gbla &nesta
6 .* now update the globals from within the macro
7 &clock setc '&sysclock'
8 &location setc '&sysloc'
9 &dsname setc '&sysin_dsn'
10 &nest setc '&sysnest'
11 &nesta seta &sysnest
12 mend
000000 00000 00020 14 r csect
15 *
16 * define globals in opencode
17 *
18 Gblc &clock,&location,&dsname,&nest
19 Gbla &nesta
20 *
21 * invoke macro to update the global values
22 *
23 getlocalsys
24 *
25 * now use the updated values
26 *
27 dc c'&clock'
000000 F2F0F0F460F0F660 + dc c'2008-07-11 17:48:42.914829'
28 dc c'&nest'
00001A F1 + dc c'1'
29 dc f'&nesta'
00001B 00
00001C 00000001 + dc f'1'
000000 31 end rRefer to Appendix C. Macro and conditional assembly language summary for a summary of the values and properties that can be assigned to system variable symbols.
[ Top of Page | Previous Page | Next Page | Contents | Index ]