How to use the Query In function

Stimulsoft Reports.JS discussion
Martijn
Posts: 9
Joined: Wed Jan 09, 2019 10:14 am

How to use the Query In function

Post by Martijn »

I have a variable with the list option, so the user can select witch item the want to see.
Schermafbeelding 2019-01-09 om 11.17.08.png
Schermafbeelding 2019-01-09 om 11.17.08.png (39.86 KiB) Viewed 3498 times
To use this variable i use the Data Source Query. Only how to select the variable correctly into the where option.
When the user select one item the result is ok, but with more items there are no results.
Schermafbeelding 2019-01-09 om 11.18.35.png
Schermafbeelding 2019-01-09 om 11.18.35.png (41.97 KiB) Viewed 3498 times
Lech Kulikowski
Posts: 6254
Joined: Tue Mar 20, 2018 5:34 am

Re: How to use the Query In function

Post by Lech Kulikowski »

Hello,

In this case, you can use ToQueryString() method for List variable.

Thank you.
Attachments
ListInQuery.mrt
(7.06 KiB) Downloaded 199 times
Martijn
Posts: 9
Joined: Wed Jan 09, 2019 10:14 am

Re: How to use the Query In function

Post by Martijn »

Thx for the reply.
Now i get the next Error.
to your MariaDB server version for the right syntax to use near '\' \') GROUP BY
Lech Kulikowski
Posts: 6254
Joined: Tue Mar 20, 2018 5:34 am

Re: How to use the Query In function

Post by Lech Kulikowski »

Hello,

We couldn't reproduce the issue. Please send us your report with test data for analysis.

Thank you.
Martijn
Posts: 9
Joined: Wed Jan 09, 2019 10:14 am

Re: How to use the Query In function

Post by Martijn »

See the attachment for my report issue.
Attachments
ListInQuery MySql.mrt
(46.71 KiB) Downloaded 133 times
Lech Kulikowski
Posts: 6254
Joined: Tue Mar 20, 2018 5:34 am

Re: How to use the Query In function

Post by Lech Kulikowski »

Hello,

Please send us a test data for your report.

Thank you.
Martijn
Posts: 9
Joined: Wed Jan 09, 2019 10:14 am

Re: How to use the Query In function

Post by Martijn »

Hi,

I have made a .csv file with some data that i want to use for this report.
The idea is very simple. The user select which item the want to see on the report. Only the IN function is for this not working.

I hope someone can help me with this.
Attachments
Testdata.csv
(8.74 KiB) Downloaded 125 times
Lech Kulikowski
Posts: 6254
Joined: Tue Mar 20, 2018 5:34 am

Re: How to use the Query In function

Post by Lech Kulikowski »

Hello,

The modified report in the attachment.

Thank you.
Attachments
ListInQuery MySql2.mrt
(6.4 KiB) Downloaded 137 times
Annotation 2019-02-15 101806.jpg
Annotation 2019-02-15 101806.jpg (73.01 KiB) Viewed 3388 times
Martijn
Posts: 9
Joined: Wed Jan 09, 2019 10:14 am

Re: How to use the Query In function

Post by Martijn »

Thank You.
Still i get the error
'ER_PARSE_ERROR: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '\' \')' at line 1'

I have not changed your report file and added the csv data as own new database.
I use the 'Stimulsoft Reports V 2019.1.1 from 17 december 2018' it is the Apple version.

So i have no idea why it is not working by me.
I use as database the program Sequel Pro.
Lech Kulikowski
Posts: 6254
Joined: Tue Mar 20, 2018 5:34 am

Re: How to use the Query In function

Post by Lech Kulikowski »

Hello,

Please clarify how do you run the sample report, step by step.

Thank you.
Post Reply