Our client has a requirement where a keyword is supposed to produce a list of records containing it and highlighted in red on a map.
The records would come from a database with an alphanumeric field of 60 bytes length which basically is a description field.
For example, search ‘APP’
Rec1 APPLICATION
Rec2 LARGE APPLICATOR
Rec3 MAPPER
Would it be possible to accomplish this in Natural Mainframe online application?
We tried using an array of control variables but they came out spaced out on the map.
Thanks Giles for your input as it helps reinforce my thinking it is not possible.
I want to ensure that there is no trick that can pull it off in my scenario.
I don’t have any suggestions for marking the full matching substring, but you could use the
MARK POSITION
to highlight the matching start character inside the fields.
But as far as I remember only on 3270 !
I’ve just dredged this up from memory. It might help. You will lose a space for the dynamic attribute but it will highlight part of the string
DEFINE DATA LOCAL
1 #FIELD (A20)
1 #CV1 (C)
END-DEFINE
REPEAT
INPUT #FIELD (AD=MY CV=#CV1 DY= )
END-REPEAT
END
Of course, ‘APP’ could just as easily be #KEY, and you could also
COMPRESS ‘<’ #KEY ‘>’ into #REPLACE instead of ‘’
One other note. you could also REPLACE FIRST in the EXAMINE if that is what the customer wants, even if there are multiple instances of the search key.
One more note. you might have to expand #FIELD to accommodate the delimiters <> (and perhaps multiple instances of them), depending on how many actual characters might be in the field.