Jasper REST pass collection as parameter

I have a report which receives a List parameter to use it in a IN clause:
 
`$X{IN, personID, _personID}`
 
The report works when running it through the web application or remote repository view in iReport.
 
Now I need to call it using the REST api. I have tried several different ways of passing the list value in my resource descriptor but none of them worked. 
 
 
    <resourceDescriptor name="Test_Report" wsType="reportUnit" uriString="/Test/Test_Report" isNew="false">
        <parameter name="_personId" isListValue="true"><![CDATA[1]]></parameter>
    </resourceDescriptor>
The above example returns the following error:
`Invalid type java.lang.String for parameter _personId used in an IN clause; the value must be an array or a collection.`
I have also try the following:
    <parameter><name>_personId</name><value isListValue="true">3</value>    </parameter>
But this returns a report with all the records, not only the person with Id=3.
felipegdr's picture
108
Joined: Apr 20 2012 - 3:51am
Last seen: 6 years 5 months ago

0 Answers:

No answers yet
Feedback
randomness