[Libreoffice-bugs] [Bug 130672] New: base sql query parameter with negative value fails
bugzilla-daemon at bugs.documentfoundation.org
bugzilla-daemon at bugs.documentfoundation.org
Fri Feb 14 18:41:02 UTC 2020
https://bugs.documentfoundation.org/show_bug.cgi?id=130672
Bug ID: 130672
Summary: base sql query parameter with negative value fails
Product: LibreOffice
Version: 6.3.4.2 release
Hardware: x86-64 (AMD64)
OS: Windows (All)
Status: UNCONFIRMED
Severity: normal
Priority: medium
Component: Base
Assignee: libreoffice-bugs at lists.freedesktop.org
Reporter: cwaynedavis at gmail.com
Description:
Simple example:
SELECT * FROM "MediaInfo" WHERE "aid" = :P1
The "aid" column is integer and has some negative integers in it. When I run
the query and enter a positive integer it works but finds no records if I enter
a negative. It does work when I replace :P1 with either '-1030' or just -1030.
Sliderule gave two workarounds:
SELECT * FROM "MediaInfo" WHERE "aid" = :P1*1
or SELECT * FROM "MediaInfo" WHERE "aid" IN ( :P1 )
He says it's an issue with Base OpenOffice / LibreOffice database parser.
Steps to Reproduce:
1. Create table1 with "ID", "AID" columns, both integer. Create data rows,
with negative numbers for "aid", ex:
ID AID
123 -1030
124 235
666 -9999
2. Create query SELECT * FROM "table1" WHERE "aid" = :P1
3. Run query, enter -1030 for prompt.
Actual Results:
No records found.
Expected Results:
123, -1030
Reproducible: Always
User Profile Reset: No
Additional Info:
Version: 6.3.4.2 (x64)
Build ID: 60da17e045e08f1793c57c00ba83cdfce946d0aa
CPU threads: 4; OS: Windows 10.0; UI render: default; VCL: win;
Locale: en-US (en_US); UI-Language: en-US
Calc: threaded
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/libreoffice-bugs/attachments/20200214/f3808544/attachment.htm>
More information about the Libreoffice-bugs
mailing list