[RESOLVED] RecordSelectionFormula and IN keyword
HI,
I want to filter a report using RecordSelectionFormula based on criteria I select at runtime.
I can get it to work for one value:
mFilterString = "{rptOutputAll;1.ADAccount} = 'abc'"
I have a list of discrete values for
account names and I want to select the records relating to more than
one. I have tried using the 'IN' keyword but cannot get it to work.
None of the following work:
mFilterString = "{rptOutputAll;1.ADAccount} IN Array(" & Chr(34)
& "abc" & Chr(34) & ", " & Chr(34) & "def" & Chr(34) & ")"
mFilterString = "{rptOutputAll;1.ADAccount} IN Array('abc','def')"
mFilterString = "{rptOutputAll;1.ADAccount} IN ('abc','def')"
How do I do this??
Re: RecordSelectionFormula and IN keyword
Got it.
Instead of using IN, use Like as follows:
mFilterString = "{rptOutputAll;1.ADAccount} LIKE ['abc', 'def']"