#1 2016-01-22 09:48:19

Mathilde
Member
Registered: 2016-01-22

CSV datasource

Hello,

I aim to use data from a CSV file. If you have a method, I would thank you a lot to share it ! Below, my unsucceeded attempts.

I have inserted a CSV datasource (with text connector) and, as mentionned in documentation, I have added a H2 internal datasource (the test connection is passed). Then, I have added a dynamic list.

Firstly, I have linked the dynamic list to the H2 database (with empty query). When selecting columns, I get the error
        "The report could not be executed: Could not open connection to: jdbc:h2:file:/opt/bitnami/apache-tomcat/temp/rsidb//rsdb with user: bitnami. Query may not be empty"

Secondly, I have linked the dynamic list to the CSV datasource. When selecting solumns, I get the error
        "The report could not be executed: java.lang.IllegalStateException: java.lang.IllegalStateException: java.lang.RuntimeException: org.h2.jdbc.JdbcSQLException: Wrong user name or password [28000-180]"

Regards

Offline

#2 2016-01-22 15:58:22

Arno Mittelbach
datenwerke
Registered: 2012-02-14

Re: CSV datasource

Hello Mathilde,

I think there might be a misunderstanding. A CSV datasource does not need an additional H2 datasource. It uses it as a backend, but this should all happen behind the scenes. To use a CSV datasource, all you need to do is to create the datasource, say with a text connector. Then input the CSV data into the text field. Then simply select the datasource as the datasource for a report or datasource parameter.

I hope this helps.

Cheers
-Arno

Offline

#3 2016-01-22 16:29:26

Mathilde
Member
Registered: 2016-01-22

Re: CSV datasource

Hello Arno,

Thanks a lot for your answer ! Good to know for the H2 database.
However, I still get the error when I try to select colums.
        "The report could not be executed: java.lang.IllegalStateException: java.lang.IllegalStateException: java.lang.RuntimeException: org.h2.jdbc.JdbcSQLException: Wrong user name or password [28000-180]"
This error is quite meaningless because there is no login for pasted text, obviously !
The problem may be in the connection to the H2 internal database ? I also wonder what query could fit a CSV list.
For information, I run with the Ubuntu VM from Bitnami and the client is on Windows.

Have a good week-end,

Offline

#4 2016-01-22 18:11:00

Arno Mittelbach
datenwerke
Registered: 2012-02-14

Re: CSV datasource

Hi Mathilde,

I just did a fresh install (on a Mac) and there it seems to work. I did the following steps:

1) Go to Datasources in admin area and create a CSV list
2) Give it a name, choose the text connector and enter

A;B;C
1;2;3
4;5;6

3) Click apply
4) go to report management and create a dynamic list
5) give it a name and choose as datasource the just created CSV list. Leave the field query wrapper blank and hit apply.
6) execute the dynamic list.

As for your error message: is there a stacktrace or anything more specific that you could post?

Cheers
-Arno

Offline

#5 2016-01-25 12:43:04

Mathilde
Member
Registered: 2016-01-22

Re: CSV datasource

Thank you Arno for the reply.
That was I did, with the error, and now it works ...

Regards

Offline

#6 2016-01-25 13:01:00

Arno Mittelbach
datenwerke
Registered: 2012-02-14

Re: CSV datasource

Glad to hear, that it works now.

Cheers
-Arno

Offline

Board footer

Powered by FluxBB