Jump to content
We've recently updated our Privacy Statement, available here ×

Multi-Value values in column, parameter needed and need a wildcard


QueenArtemis

Recommended Posts

Okay, so here it goes. Using Jaspersoft Sudio Pro 6.2.1. Oracle DB. I need some help on how to use a parameter that contains wildcard.

In my query, i have values in a column that could contain multiple values. 

1 single row containing multi values in the columns.

 multivalue1.PNG.d68da37b437cdf5d30ed5956ed7e9cf5.PNG

i need to create a parameter (multi select) to get these values. 

if i use:

AND portfolio.code LIKE '%pro_other%' within the query, this works perfectly. it will return the correct results with pro_other and then those rows that contain %pro_other%.

Now, I tried to make the parameter within the jrxml: AND $X{IN, portfolio.code, portfolioKey_1} 

This works, however, it will only give me the specific values that ONLY have "pro_other" in the values. 

I have tried this: AND portfolio.code IS NULL OR portfolio.code LIKE '%' || '$P!{portfolioKey_1}' || '%' and this gives me the error: 

java.sql.SQLException: Execute Query fail.Execute Query fail.Invalid column index

My parameter is java.util.Collection

Anyone have any ideas,  i would be so very grateful.

Sincerely,

Keri

Link to comment
Share on other sites

  • 1 year later...
  • Replies 1
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Posted Images

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...