Report Builder: Data missing with "Run SQL directly"

Getting your data onto paper - or the web - Discussing the reports features of Base

Report Builder: Data missing with "Run SQL directly"

Postby newuser » Sat Mar 29, 2008 8:19 pm

I'm running OOo 2.3.1 with Sun Report Builder 1.0.1 under Windows 2000, with any backend I've tried or even using the embedded HSQL engine it is impossible to retrieve data from a saved query if "Run SQL directly" has been selected in it.

Actually on my system reports come out but only graphic elements are printed on the screen (such as lines or images) while data is substituted by series of blank lines.

Can anyone else confirm this behaviour before I submit the bug?
newuser
 
Posts: 39
Joined: Sun Dec 02, 2007 11:06 am

Re: Report Builder: Data missing with "Run SQL directly"

Postby DrewJensen » Sun Mar 30, 2008 12:56 am

Using queries with Escape Processing turned off ( Run SQL Direct ) you should be sure to alias your return columns.

Give that a try and see if your problems don't go away.
Former member of The Document Foundation
Former member of Apache OpenOffice PMC
LibreOffice on Ubuntu 18.04
User avatar
DrewJensen
Volunteer
 
Posts: 1734
Joined: Sat Oct 06, 2007 9:01 pm
Location: Cumberland, MD - USA

Re: Report Builder: Data missing with "Run SQL directly"

Postby newuser » Sun Mar 30, 2008 11:09 am

Thanks for your reply, I've tried with aliases but it seems to make no difference.

I've created a new database file connecting to the example file biblio.dbf installed with OOo in the directory /openoffice.org2.3/preset/database/biblio.

I've created the following query using the SQL view
Code: Select all   Expand viewCollapse view
SELECT
  "Identifier" AS "IDENTIFIER",
  "Type" AS "TYPE",
  "Author" AS "AUTHOR"
FROM
  "biblio" as "BIBLIO"
and I've checked the "Run Sql command directly" option. I can create a new report picking this query as data source, field names appear correctly in the "Add field" window but once the report is run I obtain only a blank page. Turning on escape processing in the same query solves the problem, unfortunately this solution doesn't support the full SQL syntax available for the backend (e.g. with SQLite I can't use the CASE instruction).

Same result if I import the table into a database which uses the embedded HSQL engine.

I will probably try to install OOo 2.4.0 for *nix to see if it makes any difference.
newuser
 
Posts: 39
Joined: Sun Dec 02, 2007 11:06 am


Return to Reporting

Who is online

Users browsing this forum: No registered users and 2 guests