Skip to main content



      Home
Home » Archived » BIRT » SQL with Parameters
SQL with Parameters [message #1772441] Sat, 09 September 2017 17:21 Go to next message
Eclipse UserFriend
I'm new to BIRT, so please excuse my naivete. I'm working on a BIRT report that uses report parameters at runtime. These are linked to the appropriate dataset parameters, but the report fails with an error message that suggests the parameters are not effectively passing to the actual SQL query.

Is there a way to see the actual query string passed to the server? I tried setting the logging level to FINEST, and even though this logs the query, it doesn't appear to log the value of the parameters. After running the nonworking report and finding the "?" markers still in the string, I ran a report that works without error, and it too showed the markers and not the runtime values.

Any help would be appreciated.

Thanks,
Dave

[Updated on: Tue, 12 September 2017 14:34] by Moderator

Re: SQL with Parameters [message #1772580 is a reply to message #1772441] Tue, 12 September 2017 11:37 Go to previous messageGo to next message
Eclipse UserFriend
Check this site http://developer.actuate.com/community/articles.html/_/articles/birt-books/le-birt-experts-guide-to-birt-best-practices-r24

the eBook 'LeBIRT; Experts Guide to BIRT Best Practices' has some code for creating a Debug Window. It will allow you to view 'this.queryText' and other data elements. It's the best debugging tool I have found.
Re: SQL with Parameters [message #1772581 is a reply to message #1772580] Tue, 12 September 2017 11:39 Go to previous messageGo to next message
Eclipse UserFriend
Free Alternative:
You can grab the complete query in the dataSet script with 'this.queryText'. Set it to a variable (i.e. myScript') in the Data Set 'afterOpen' method and display it on the report in a dynamic text element to view it.
// Capture the complete Query
reportContext.setPersistentGlobalVariable("myScript",this.queryText.toString());

myScript (place in a dynamic text element)
Re: SQL with Parameters [message #1772593 is a reply to message #1772580] Tue, 12 September 2017 14:47 Go to previous messageGo to next message
Eclipse UserFriend
The link to the book doesn't work. I tried searching Google too but found no links to buy the book. Are you aware of anyplace where it may be available?

Thanks,
Dave
Re: SQL with Parameters [message #1772698 is a reply to message #1772593] Thu, 14 September 2017 00:39 Go to previous messageGo to next message
Eclipse UserFriend
https://www.scribd.com/doc/30215544/Le-BIRT-Expert-s-Guide-to-BIRT-Best-Practices
Re: SQL with Parameters [message #1772729 is a reply to message #1772698] Thu, 14 September 2017 08:34 Go to previous message
Eclipse UserFriend
That's just a 43 page intro to the book. The book itself is over 300 pages.
Previous Topic:Export to pdf is failing to produce a valid pdf file
Next Topic:Birt Error while running reports
Goto Forum:
  


Current Time: Sun Jul 27 02:27:34 EDT 2025

Powered by FUDForum. Page generated in 0.04844 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top