# Dynamic variables in "strict" report mode

**URL:** <https://techcommunity.softwareag.com/t/dynamic-variables-in-strict-report-mode/265198>\
**Category:** Forum\
**Tags:** Adabas-Natural, EntireX\
**Created:** [October 26, 2022, 8:45pm UTC](https://techcommunity.softwareag.com/t/dynamic-variables-in-strict-report-mode/265198 "2022-10-26T20:45:06Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Steve.Tomsko](https://avatars.discourse-cdn.com/v4/letter/s/3da27b/32.png) [@Steve.Tomsko](https://techcommunity.softwareag.com/u/Steve.Tomsko)\
**Post date:** [October 26, 2022, 8:45pm UTC](https://techcommunity.softwareag.com/t/dynamic-variables-in-strict-report-mode/265198/1 "2022-10-26T20:45:06Z")

</div>

Developers have created new subprograms that will be sending data to webMethods. The PDAs for the subprogram, as well as the “listeners”, were generated by webMethods; the PDA contains DYNAMIC variables. However, the VERY OLD programs that will CALLNAT to the subprogram(s) are strictly report mode programs/subprograms (no DEFINE DATA LOCAL statements). Therefore, they need to add the layout of the PDAs that will be used to CALLNAT the listeners into the report mode programs. If we add a ‘DEFINE DATA LOCAL USING …’ statement to the calling program, then NATURAL enforces the rule that ALL program variables must be in the DEFINE DATA. Some of these programs have literally hundreds of variables (in Report Mode) that are defined “on the fly”. How to get around this?? How to define DYnAMIC variables in Report Mode??

---

<div class="post-metadata">

**Author:** ![Jerome\_LeBlanc](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/jerome_leblanc/32/111_2.png) [@Jerome\_LeBlanc](https://techcommunity.softwareag.com/u/Jerome_LeBlanc)\
**Post date:** [October 26, 2022, 9:09pm UTC](https://techcommunity.softwareag.com/t/dynamic-variables-in-strict-report-mode/265198/2 "2022-10-26T21:09:46Z")

</div>

Steve,  
One possibility is to create a subprogram to sit between the very old programs and the new subprogram. The middle-ware subprogram could have simpler parameters that could be added to your report mode programs and local data that has the dynamic variables needed by the new subprogram. There would be limitations of course.

The better option is to bite the bullet and convert the report mode programs, but we do what we can.

---

<div class="post-metadata">

**Author:** ![Douglas\_Kelly](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/douglas_kelly/32/102_2.png) [@Douglas\_Kelly](https://techcommunity.softwareag.com/u/Douglas_Kelly)\
**Post date:** [October 26, 2022, 11:44pm UTC](https://techcommunity.softwareag.com/t/dynamic-variables-in-strict-report-mode/265198/3 "2022-10-26T23:44:12Z")

</div>

Green-screen editor can still do this:

```auto
Local Library YYYYYY  
Command                             
I T L Name                         
All -- -----------------------------
  . i( reportmd)                    
                                    
                                      

```

where “reportmd” is a reporting mode program of great complexity:

```auto
RESET #A(A50)              
  #B (I2)                  
  #C (A20)                 
*                          
READ (10) EMPLOYEES BY ISN 
  DISPLAY PERSONNEL-ID     
LOOP                       
*                          
END

```

The .i(program) editor command pops up a selection dialog

```plaintext
                                            
                                            
  Please select :                           
                                            
 X All local variables and parameters      
 _ All local variables                     
 _ Only internally defined local variables 
 _ All parameters                          
 _ Only internally defined parameters      
                                            
 X All defined variables                   
 _ Used variables only                     
 _ Unused variables only                   

```

Mark your preference for variables to be included, press enter to see the variables inserted into your local data area:

```auto
Local Library YYYYYY DBID 274 FNR 25
Command > +
I T L Name F Length Miscellaneous             
All -- -------------------------------- - ---------- ------------------------->
  * /* INSERTED FROM REPORTMD 
     1 #A A 50                           
     1 #B I 2                           
     1 #C A 20                           
  V 1 EMPLOYEES-VIEW EMPLOYEES                 
     2 PERSONNEL-ID A 8                           
  * /* END OF REPORTMD        
                                                                               

```

Hope that helps!

---

<div class="post-metadata">

**Author:** ![sikhokho](https://avatars.discourse-cdn.com/v4/letter/s/cdc98d/32.png) [@sikhokho](https://techcommunity.softwareag.com/u/sikhokho)\
**Post date:** [October 27, 2022, 3:20am UTC](https://techcommunity.softwareag.com/t/dynamic-variables-in-strict-report-mode/265198/4 "2022-10-27T03:20:54Z")

</div>

This post was flagged by the community and is temporarily hidden.

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/techcommunity/original/3X/c/d/cd19967bb605d28a72d77eb83a1cae22f3df2eb8.svg) [@system](https://techcommunity.softwareag.com/u/system)\
**Post date:** [April 25, 2023, 3:21am UTC](https://techcommunity.softwareag.com/t/dynamic-variables-in-strict-report-mode/265198/5 "2023-04-25T03:21:04Z")

</div>

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.
