[Libreoffice-bugs] [Bug 117148] New: FIREBIRD allows no edit for table with unique index, but no primary key, contrary to message
bugzilla-daemon at bugs.documentfoundation.org
bugzilla-daemon at bugs.documentfoundation.org
Sat Apr 21 20:33:06 UTC 2018
https://bugs.documentfoundation.org/show_bug.cgi?id=117148
Bug ID: 117148
Summary: FIREBIRD allows no edit for table with unique index,
but no primary key, contrary to message
Product: LibreOffice
Version: 5.3.7.2 release
Hardware: All
OS: All
Status: UNCONFIRMED
Severity: normal
Priority: medium
Component: Base
Assignee: libreoffice-bugs at lists.freedesktop.org
Reporter: gerhard.weydt at t-online.de
When you create a table in Base with Firebird database and save it without
having created a primary key, you get the following dialog:
No primary key
A unique index or primary key is required for data record identification in
this database.
You can only enter data into this table when one of these two structural
conditions has been met.
Should a primary key be created now?
But, following the alternative stated and creating a unique index only leaves
the table not editable. Only if a primary key is added, it becomes editable.
Steps to reproduce (or open attachment TableOnlyUniqueIndex):
1. create a new database document with Firebird database engine
2. create a table using Design View, with some columns
3. save the table; you will get the message shown above
4. reject the creation of a primary key by answering: No
5. choose Tools -> Index design or its symbol
6. create a unique index for the first two columns and save it
7. close the index and table dialogs
8. save the database document
9. open the table for editing
Result: the table is not editable
Expected result: the table should be editable, as stated explicitly in the
message shown above.
It doesn't help to close the document and to open it gain, the situation
remains unchanged.
To show that editability really depends from a primary key:
10. open the table definition for editing
11. create a new column or select one of the columns not used for the unique
index
12: right-click the header of the row describing this column and choose
"Primary Key"
13. save the table definition
After that the table can be edited.
Remark: for HSQLDB primary keys were always mandatory, maybe the same test
applies now to firebird. But for HSQLDB there is no message that you can use a
unique index instead!
This issue is connected with bug 117092, saying (despite its title, because the
fact was only discovered after the bug had been created) that it is not
possible to create a primary key with more than one column.
In the present state one would have to create
1. a unique index with the columns needed
2. a primary key with one column
where one index could be sufficient.
tested with:
Version: 6.1.0.0.alpha0+
Build ID: 9c4eaa7b81a40d97fe49b85272b40bfeaaf44f86
CPU threads: 4; OS: Windows 10.0; UI render: default;
TinderBox: Win-x86 at 42, Branch:master, Time: 2018-04-16_03:31:36
Locale: de-DE (de_DE); Calc: group
--
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/20180421/777edf01/attachment.html>
More information about the Libreoffice-bugs
mailing list