https://bugs.documentfoundation.org/show_bug.cgi?id=153317

            Bug ID: 153317
           Summary: MySQL/MariaDB direct connection: Content of field type
                    'Bit' isn't shown in Tools → SQL
           Product: LibreOffice
           Version: 7.4.5.1 release
          Hardware: x86-64 (AMD64)
                OS: Linux (All)
            Status: UNCONFIRMED
          Severity: normal
          Priority: medium
         Component: Base
          Assignee: [email protected]
          Reporter: [email protected]

You will need a direct connection to MariaDB (or MySQL) for testing this bug.
Create a field in a table as field type bit(1). Something like

CREATE TABLE `test`.`tbl_Test` (
  `ID` int(10) NOT NULL PRIMARY KEY,
  `Text` varchar(100) DEFAULT NULL,
  `Confirm` bit(1) DEFAULT NULL
);

Add some content and click on "Confirm" for some rows.
Execute this query in SQL-Mode:
SELECT * FROM `test`.`tbl_Test`
Will show the content of `Confirm` without problems.

Now go to Tools → SQL. Set "Show output …".
Execute the same query.
No content appears for column `Confirm`.

Same behavior will appear if you start the query by macro. No value could be
found.

Change the query:
SELECT `ID`, `Text`, CASE WHEN `Confirm` THEN 1 ELSE 0 END FROM
`test`.`tbl_Test`

This query will give the correct 'values' for `Confirm`. Field type bit(1)
couldn't be read directly through Tools → SQL or by macro with direct
connection to MariaDB.
This bug won't appear with JDBC connection to the same database.

Tested with LO 7.4.5.1 on OpenSUSE 15.3 64bit rpm Linux.

-- 
You are receiving this mail because:
You are the assignee for the bug.

Reply via email to