Jump to content

How to enable -on-demand settings for multiple parameters


Chun Seong Low

Recommended Posts

Hi

I have a question on how can I apply on-demand settings for multiple input parameters? Currently, I only managed to achieve that by allow 1 input parameters, the parameter is coming from user entry value, linked to properties control. But I want to add in more parameters, sometime user want to filter by parameters A, sometime parameters B, it is always filter by either 1 parameters and NOT both.

Appreciate if anyone could advice. Thanks.

Link to comment
Share on other sites

Hello,

This is labelled (the topic is set) as both Jaspersoft Studio and Spotfire. To increase the change of receiving an answer, please clarify what product your are referring to. 

Assuming that this is Spotfire, could you please explain the use case in a bit more detail?

Do you e.g. have multiple different parameters (let's say age and name), that should control different columns in the on-demand query, resulting in a SQL statement like   

....

WHERE

  (T1.AGE = 20

  AND T1."NAME" = 'BOB')

By default this would, as in the example above, filter on both, i.e. do an AND. Are you trying to only filter on one at a time (e.g. WHERE

  (T1.AGE = 20), somehow determined by what the user has selected/entered. As you have the ability to use expressions as input, so you can add some logic to what should be used, that might be what you should look into using.

  

OR

Do you have a single property, that should control a single column in the on-demand query, that can contain multiple values

example:

WHERE

  (T1.NAME IN ('BOB', 'SUE')

  

  

OR

Something else

Link to comment
Share on other sites

Hi

Yes, this is for Spotfire.

Default, I load the entire data set, with lots of columns. On the design page, I would create 3 input field, all free text entry, and user allow to key in anything they want in the fields (each with multiple values), assuming the 3 fields are Name, State and Country.

Scenario 1, user would like to only search for certain Name only, and leave State & Country empty, and I would like the on-demand settings to filter by whatever user entered.

Scenario 2 would be same idea, but say they want to filter by Country, and both the others empty.

Currently, I am using on-demand settings and what I have done is enabled a single entry field with multiple values, which works great. Beyond that, I could not find a way for multiple entry field.

Regards

Link to comment
Share on other sites

  • 1 month later...

Hi

I still could find a direct solution for this, ended up I did something else, which manage to give me what I want.

For each parameter that I need to apply filter, I create a dedicated page for it, so 1 page, 1 properties control, 1 parameter. It is repetitive but no conflicts and it get the job done.

Hope this helps.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...