Products Resources Support About Us

Rocket Software

D3/win select list processing via DataBasic question

This one’s a puzzler.

In my app I have a COMMON array variable which contains a list of item keys built via another process. [This was done for performance issues to save the system always having to select from an entire large file.] Let’s call it a sub-set.

I now want to utilise that sub-set within a Databasic routine but then want to perform further ‘filtering’ of that same sub-set; expecting the results to be nearly instantaneous. For the filtering selection I want to use an EXECUTE.

The general steps in the Databasic process would be:

EXECUTE.STRING = 'SELECT SOMEFILE WITH SOMECRITERIA = “ABC” ’ ;* This will be my filter
SELECT COMMONLISTVAR TO SOMELIST ;* This I expect to create an active list
EXECUTE EXECUTE.STRING CAPTURING DUMMY RETURNING RETVAR ;* This I expect to filter my active list returning a shorter active list

But it doesn’t. It appears the EXECUTE does not ‘inherit’ the active-list. I guess that’s reasonable as an EXECUTE pushes a level and spawns a new workspace; but my question then is:

How do I achieve what I want? The only thing I can think of [which I consider clumsy] is to write out the common select list into POINTER-FILE [thus create a ‘gettable’ get-list]; and stacking two commands in the EXECUTE to firstly perform a get-list and then the filtering execute thus returning an active list to Databasic.

Anyone got any better ideas?

[I hope I’m explaining myself]