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

How to pass Multivalued Parameter to jasper reports?


prachu.kul

Recommended Posts

I want to display data for multiple locations by passing location codes which are of Integer type to the query.

For that I used $X{ IN, loc_cd, loc_codes } where loc_cd is column_name and loc_codes is parameter_name of java.util.Collection type.

But the error comes as "net.sf.jasperreports.engine.JRException: net.sf.jasperreports.engine.JRRuntimeException: No clause function for id IN found".

Please,  help me out.

Thanks in advance.

Link to comment
Share on other sites

  • Replies 3
  • Created
  • Last Reply

Top Posters In This Topic

Just an FYI I'm still some what new to JasperReports myself, but I will try to not mislead you.

I personally have never seen $X in any of my source code. Also, I do not see any out of box IN functions either.

If I am understanding what you want, you could configure your main query to pull those location codes you want.

If you are wanting to do the location codes as a parameter where people can select multiple locations, then that will have to be set up on the JasperReports Server.

Link to comment
Share on other sites

Thanks for reply buddy....

I've configured jasper server also where m deploying JRXML.but before deploying it,is there any way to add In parameter to query from input control?

I've my main PLSQL query like...."blah blah....IN( 1 , 2 , 3 ,4 ) "

here 1,2,3,4 are multiple parameters of integer type which i've to pass from input control(now i've done this hardcoded).If I take 1,2,3,4 as String then it's giving me exception of class cast.i.e String cannot be cast into Integer.I can't change IN parameter datatype on database side.

If you are facing same problem,plz let me know how to solve this.Any hint,any suggestion will make huge difference.

Thanks again.

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