Bug 121755 - Libreoffice Base Union All Issue
Summary: Libreoffice Base Union All Issue
Status: RESOLVED NOTABUG
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Base (show other bugs)
Version:
(earliest affected)
6.1.0.0.alpha1+
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-11-28 12:30 UTC by perie_gut
Modified: 2018-11-28 14:20 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
sample (3.90 KB, application/vnd.oasis.opendocument.database)
2018-11-28 12:30 UTC, perie_gut
Details

Note You need to log in before you can comment on or make changes to this bug.
Description perie_gut 2018-11-28 12:30:13 UTC
Created attachment 147093 [details]
sample

tried UNION ALL in Libeoffice but received an error:


firebird_sdbc error:
*Dynamic SQL Error
*SQL error code = -204
*Table unknown
*TABLE_1
*At line 2, column 1
caused by
'isc_dsql_prepare'



how to reproduce:
1. open the attached file
2. go to "Queries"
3. Open a query. Error.
Comment 1 Xisco Faulí 2018-11-28 13:20:01 UTC
Regression introduced by:

https://cgit.freedesktop.org/libreoffice/core/commit/?id=a29d97e6ddab8ec002ba9827bd5fc874117712e0

author	Lionel Elie Mamane <lionel@mamane.lu>	2018-01-02 22:49:31 +0100
committer	Lionel Elie Mamane <lionel@mamane.lu>	2018-01-04 07:50:22 +0100
commit a29d97e6ddab8ec002ba9827bd5fc874117712e0 (patch)
tree cbedfb8885b7980a4ea6ebb1347e2170a969b01a
parent 1bbadad79d91005dc18a3c1e34de14d02660f6ab (diff)
tdf#104986 move named parameters substitution into generic layer

Bisected with: bibisect-linux64-6.1

Adding Cc: to Lionel Elie Mamane
Comment 2 Lionel Elie Mamane 2018-11-28 14:18:40 UTC
Add double quotes (") around table and column names. It seems Firebird requires it.

These queries have the "Run SQL command directly" bit set. Before my commit mentioned in comment 1, LibreOffice would round-trip these queries through the LibreOffice parser, thus normalising them and adding double quotes where needed. This explains why my commit makes a difference. But this was a bug. "Run SQL command directly" commands should not be touched, not a single character, and sent to the database engine as is.