Hi,
Probably I'm missing something basic, but the following code doesn't compile:
try (Connection con = sql2o.open())
{
Collection<Map<String, Object>> result = con.createQuery(sql.toString()).executeAndFetchTable().asList();
JRMapCollectionDataSource dataSource = new JRMapCollectionDataSource(result);
...
I'm getting this error: The constructor JRMapCollectionDataSource(List<Map<String,Object>>) is undefined
Class constructor looks like this: public JRMapCollectionDataSource(Collection<Map<String,?>> col)
I tried to change result to Collection<Map<String, ?>>, but then I get this: Type mismatch: cannot convert from List<Map<String,Object>> to Collection<Map<String,?>>
Is there any workaround better than iterate the map returned by Sql2o and create a new one that will be compatible with JasperReports?
Sql2o version is 1.5.4, JasperReports version is 5.5.0.
Thanks