Getting past a "(" in multi-select parameters?

SailRCGSailRCG Junior Member
edited December 31, 1969 in Designing Analytics Reports
Hi,

I have a set of multi-select paremeters, working fine within the report implemented to modify the where clause dynamically. Some of the multi-select data values contain “(“ and “)”. These work fine within the report to re-query and show a filtered data set to the report.

However, I am also using these parameters when I call a report that has the same set of parameters. These seem to be causing a problem when I pass the values to the receiving report.

For example, if I pass a list of parameters using;
‘if(paramsSomeParameter[“myParameter”].value!=null)
{paramsSomeParameter[“myParameter”].value.join()}’
might pass something like:
Cars,Planes,Trains
to the receiving report and all will be fine. However, if the selection contains a value having a parenthesis I will have a problem. For example;
Cars,Planes,Boats (Personal), Boats (Commercial)
The thing will pass something like;
Cars, Planes, Boats … stopping at the '(' and that’s all.
Because of this, the query will not contain all the correct values. I’ve attempted some work with the split() function and an array… but I am not able to make that work.

Does anyone have any ideas how to handle this kind of data / parameter issue?

Thanks,

RG

Comments

  • mwilliamsmwilliams BIRT Guru
    edited December 31, 1969
    Hi RG,

    You may try something like the following to loop through and check for the left parenthesis:

    while (param["myParameter"].match("(") != null){
    param["myParameter"].replace("(","");
    }

    Then, also do the same for the right ones. I have not tried this, but I would guess it should work. Let me know.

    Regards,

    Michael Williams

    eSignLive Evangelism & Community Manager | eSignLive by VASCO
     
    Find me on:
    Twitter
    Facebook
    Blog

    LinkedIn

    eSignLive Developer Community
     
    Email me:
    Google: [email protected]

Sign In or Register to comment.