How to pass subDataset in list component


I am new in Jasper report 


In my project I have use the version of jasper report is 6.3.1 and take a datasource as json data sorce.

In my report designing portion I have created one subDataset and take one list component . Now i want to use that subDataset  into my list component so how this task is achive.

I have try to take dataSourceExpression like :


but its produce the exception like 

Caused by: java.lang.ClassCastException: net.sf.jasperreports.engine.JREmptyDataSource cannot be cast to

nidhi.naik's picture
Joined: Aug 3 2017 - 4:04am
Last seen: 3 years 10 months ago

1 Answer:



In first, check if the default data_adapter has been defined like:

<property name="" value="src\main\resources\data_adapter.json"/>

if it is not, you get the error message by try to run you report

alexander.nemzew's picture
Joined: Sep 11 2017 - 5:29am
Last seen: 3 years 9 months ago