Jump to content

Issues with Passing Multi select parameter from main report to subreport


mailtojustine

Recommended Posts

I have a main report from which parameter ProjectID is multi select. The main report is working fine. But after adding the subreport I am getting an error

"java.lang.ClassCastException: java.util.ArrayList cannot be cast to java.math.BigDecimal"

In Main Report

Query part :  where $X{IN, i.id, ProjectID}

Parameter Name : ProjectID, Class : java.util.Collection, Nested Type : java.math.BigDecimal

In Subreport

Query part :  where i.id=$P{ProjectID}

Parameter name : ProjectID, Class : java.math.BigDecimal

Can anyone please help me to resolve this problem?

 

Thanks,

Justine

Link to comment
Share on other sites

  • Replies 7
  • Created
  • Last Reply

Top Posters In This Topic

Thanks. Report is running in that case. But I am not getting the desired report output. Each time all the array list is passing to subreport. It is wrong.

Means, Suppose I am passing 2 Projects P1 and P2 as parameters from main report, the result now I am getting is,

1st page

Main report data P1, Sub report data P1, Sub report data P2

2nd page

Main report Data P2, Sub report data P1, Sub report data P2

But, the desired result should be like this,

1st page

Main report data P1, Sub report data P1

2nd page

Main report Data P2, Sub report data P2.

 

Any idea for getting this result?

 

Link to comment
Share on other sites

  • 8 months later...
  • 3 weeks later...

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