Bug 126639 - Auto_increment issue editing Base
Summary: Auto_increment issue editing Base
Status: RESOLVED DUPLICATE of bug 122446
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Base (show other bugs)
Version:
(earliest affected)
6.1.2.1 release
Hardware: x86-64 (AMD64) All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-07-31 14:11 UTC by Mac
Modified: 2019-08-06 14:38 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Mac 2019-07-31 14:11:57 UTC
Description:
I tried to create a new table in Base (actually 6.2.5, but happend also before). I defined a primary Key with auto increment. If I don't put any other column in the table, everything is ok. If I try to add a column, the auto increment option is set to no - and I can't edit any setting of any column after saving. In former versions, the auto increment worked. When I create a table with the assistant and fill in to the auto increment option AUTO_INCREMENT according to the help file, there occurs an error note that AUTO_INCREMENT is unknown. If I don't write the text into the option, the column is created with no autoincrement, despite I marked the option in the dialogue for the primary key. If You need some screenshots, feel free to contact me.

Steps to Reproduce:
see Description

Actual Results:
primary key is created without autoincrement, columns are not to be edited any more

Expected Results:
autoincrement setting should be preserved even after editing columns. Columns should be to edit after saving


Reproducible: Always


User Profile Reset: No



Additional Info:
Auto-Increment-Ausdruck

From HELP (German Version):
Geben Sie den SQL-Befehlsparameter ein, der die Datenquelle anweist, ein bestimmtes Integer-Datenfeld als Auto-Increment-Datenfeld zu behandeln. Der folgende MySQL-Befehl verwendet beispielsweise den AUTO_INCREMENT-Befehl zum Hochzählen des "id"-Feldes, wenn durch den Befehl ein Datenfeld erstellt wird:

CREATE TABLE "table1" ("id" INTEGER AUTO_INCREMENT)

Für dieses Beispiel müssen Sie AUTO_INCREMENT in das Feld Auto-Increment-Befehl eingeben.

This throwed me an error
Comment 1 Alex Thurgood 2019-07-31 15:12:57 UTC
@Mac :

Sorry, we need more information.

1) Which database type are you using ? Above all, the type of database engine conditions the type of autoincrement statement to be used as they are different for each one.

For example:

mysql uses AUTO_INCREMENT

hsqldb uses GENERATED BY DEFAULT AS IDENTITY(START WITH n) where n is the integer with which to start counting

firebird uses a different GENERATOR DDL statement :

postgresql uses the SERIAL data type

etc, etc.

As you can see, we need to know which db engine you are using.
Comment 2 Alex Thurgood 2019-07-31 15:15:39 UTC
Sounds to me like your report is a DUPLICATE of bug 42905
Comment 3 Robert Großkopf 2019-07-31 17:12:23 UTC
Could also be bug 122446, if it is a MySQL/MariaDB?

Have tested this with LO 6.2.5.2 on OpenSUSE 15 64bit rpm Linux:
Created a table in design view,
first field ID, set AutoValue 'yes',
second field Name.
Switched back to field ID and see AutoValue is set.
Saved the table and opened it for input data.
Autoincrement is working in field ID.

works in both internal databases, HSQLDB and Firebird.
Comment 4 Alex Thurgood 2019-08-01 14:23:00 UTC
(In reply to Robert Großkopf from comment #3)
> Could also be bug 122446, if it is a MySQL/MariaDB?
> 
> Have tested this with LO 6.2.5.2 on OpenSUSE 15 64bit rpm Linux:
> Created a table in design view,
> first field ID, set AutoValue 'yes',
> second field Name.
> Switched back to field ID and see AutoValue is set.
> Saved the table and opened it for input data.
> Autoincrement is working in field ID.
> 
> works in both internal databases, HSQLDB and Firebird.

Indeed, given the initial comments relating to the help, let's assume that Mac is using a mysql db, and mark this as a duplicate of bug 122446.

I had already flagged that bug under "see also".

Seems to me that the problem is quite commonplace and applicable to various different types of db backend.

*** This bug has been marked as a duplicate of bug 122446 ***
Comment 5 Mac 2019-08-06 14:38:57 UTC
sorry for late answer - was very busy. I use HSQLDB on my WIN 7 System.