Bug 56242 - Libreoffice Base should handle tables without a primary key better
Summary: Libreoffice Base should handle tables without a primary key better
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Base (show other bugs)
Version:
(earliest affected)
3.5.6.2 release
Hardware: Other All
: medium enhancement
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
: 81430 (view as bug list)
Depends on:
Blocks: 56243
  Show dependency treegraph
 
Reported: 2012-10-21 05:49 UTC by Rolf Leggewie
Modified: 2022-02-02 19:11 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
This is the https://bugzilla.novell.com/attachment.cgi?id=251407 test case (3.02 KB, text/plain)
2015-07-26 08:57 UTC, Rolf Leggewie
Details
This is the https://bugzilla.novell.com/attachment.cgi?id=251613 screenshot (17.70 KB, image/png)
2015-07-26 09:02 UTC, Rolf Leggewie
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Rolf Leggewie 2012-10-21 05:49:51 UTC
originally reported as - https://bugzilla.novell.com/show_bug.cgi?id=444129

I think LO should handle tables without a primary key better (cf.
http://qa.openoffice.org/issues/show_bug.cgi?id=54168 as well)  Right now, when
you open such a table, it is opened as non-editable, leaving the user to wonder
about the reason.  I think the user should at least receive a warning about
this, possibly coupled with a suggestion to visit a website where more details
and possible solutions can be given (I understand there are some issues with
handling tables without primary keys and there is not one single, best answer)

Steps to reproduce:

1) Load https://bugzilla.novell.com/attachment.cgi?id=251407 into a MySQL
server of your choice
2) Create new database and connect to above database
3) optional: enable logging for your MySQL server
4) double click on table accounts which does have a primary key
5) double click on table accounts_ext which does not

Observe the difference between 4 and 5 in that cells in 4 are editable where
those from 5 are not.

FWIW, OOo/LO emits a useful warning when creating a table without a primary key: https://bugzilla.novell.com/attachment.cgi?id=251613
Comment 1 Robert Großkopf 2012-10-24 19:50:02 UTC
I have changed this bug to new. Its an enhancement, which isn't included yet. Also changed the Importance to "enhancement".
Comment 2 Alex Thurgood 2015-01-03 17:40:31 UTC Comment hidden (no-value)
Comment 3 Rolf Leggewie 2015-07-26 08:57:47 UTC
Created attachment 117443 [details]
This is the https://bugzilla.novell.com/attachment.cgi?id=251407 test case
Comment 4 Rolf Leggewie 2015-07-26 09:02:54 UTC
Created attachment 117444 [details]
This is the https://bugzilla.novell.com/attachment.cgi?id=251613 screenshot
Comment 5 Rolf Leggewie 2015-07-26 09:04:23 UTC
The situation in 4.2.8.2 is still as originally described
Comment 6 Rolf Leggewie 2015-08-03 13:31:54 UTC
I was trying to verify this today in 4.4.5 and 5.1.0.0.alpha1+ but I did not see how to connect to MySQL directly.  Only JDBC and ODBC were offered.  Is this something Ubuntu-specific, some kind of extension that needs to be added or something that was dropped since 4.2.8.2?
Comment 7 Robert Großkopf 2015-08-03 13:40:30 UTC
(In reply to Rolf Leggewie from comment #6)
> I was trying to verify this today in 4.4.5 and 5.1.0.0.alpha1+ but I did not
> see how to connect to MySQL directly.  Only JDBC and ODBC were offered.  Is
> this something Ubuntu-specific, some kind of extension that needs to be
> added or something that was dropped since 4.2.8.2?

You need an extension:
http://extensions.libreoffice.org/extension-center/mysql-native-connector

Works here also with LO 4.4. without problems.
Comment 8 Rolf Leggewie 2016-08-31 09:17:54 UTC
FWIW, I have version 1.0.2 of that extension since that is what's packaged for Ubuntu trusty.  Not sure if that's where the difference comes from.  I cannot activate the more recent 1.0.4_3 alongside.
Comment 9 Rolf Leggewie 2016-08-31 10:33:17 UTC
Where does that particular newer version come from anyhow?  LO itself still has only 1.0.2 as oneh can see from https://cgit.freedesktop.org/libreoffice/core/tree/mysqlc/source/description.xml#n23
Comment 10 Julien Nabet 2022-02-02 19:11:24 UTC
*** Bug 81430 has been marked as a duplicate of this bug. ***