Education, education, education.
You are obviously new to Natural, and have never had any education in Natural.
Wolfgang told you what had to be done, but you have no idea how to do it.
Consider the following program excerpt:
IF #FIELD = &CONDITION
At compile time, Natural looks for a global variable (old style), or a variable in a GDA (new style) that is called +CONDITION. The compiler then takes the contents of +CONDITION and replaces &CONDITION in the program.
So, you need a “driver” program, such as shown below (old style)
INPUT ‘enter logical condition here==>’ +CONDITION (A50)
- validate entered value here
IF condition entered is okay
RUN ‘REPORT’ /* where REPORT is the program with the &CONDITION above.
Suppose the user enters #TEST-VALUE for +CONDITION
When you RUN ‘REPORT’ the first thing Natural does is compile the program REPORT. When Natural “sees” &CONDITION, it replaces it with #TEST-VALUE. You now have a valid Natural statement, namely
IF #FIELD = #TEST-VALUE
Suppose the user enters ‘ABC’ for +CONDITION
You now have the valid Natural statement
IF #FIELD = ‘ABC’
Your employer should supply Natural education !!