Consume sql server data
-
Hi. I'm new to jsreport. I followed this guide https://jsreport.net/blog/pdf-reports-in-sql-server but I got stuck because it is an old version. I'm working with the latest version of jsreport and it does not work for me, nor does it show any error or show any data, it just stays blank. Please someone can update the theme. What are the new steps to be able to consume sql server data from jsreport?
-
hi! i checked the post and it looks up to date with last version of jsreport (v2), there are only some screenshots about jsreport studio that are old but it does not make any difference for the purpose of the post. maybe you forgot to assign the script (in which you do the
mssql
connection) to the template, you can do that using these options:
-
thanks for answering. This is my template screen.
and this is the script
tcp/ip is activated
the result is blank, it shows nothing. It does not show any error either. I'm lost.
What I can be doing wrong?
-
Is your SQL Browser service running?
Maybe rather paste the code into the extra js file and debug it with vscode.
-
Hola. yes, sql browser service running.
vscode.
version of my sql server
-
Greetings. I found the solution. this code worked for me. I can already consume data from sql server.
-
this got it working for me as well (was having no luck using the original blog post!)
would be great to see the docs updated with an example that explains the logic to help folks get started