Skip to Content
0
Jul 03, 2013 at 02:11 PM

Formula that returns Array from Parameter in Crystal?

518 Views

I have a parameter called {?SIC} that allows users to enter multiple unique values OR enter the word "ALL".

I am trying to write a formula that checks whether the user entered multiple values or "ALL" and then have the formula return the array from the parameter (something along the lines of the formula below):

IF {?SIC}[ubound({?SIC})] in "ALL"

THEN {zzcrm110.T$CSIC} // standard field containing all values

ELSE {?SIC}[ubound({?SIC})] // array

I then want to pass this formula into select expert.

Currently the above formula only filters on the last {?SIC} value that is inputted. For example, if the user enters "3577" and "3514", the report will only filter on 3514.

Any insight on this one would be greatly appreciated! Please note that I am only a beginner when it comes to working with arrays. Thanks in advance for the help!