Bug 125186 - AutoValue does not work with PostgreSQL
Summary: AutoValue does not work with PostgreSQL
Status: RESOLVED DUPLICATE of bug 60643
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Base (show other bugs)
Version:
(earliest affected)
5.4.0.3 release
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-05-09 07:39 UTC by Sébastien Ducoulombier
Modified: 2019-05-13 06:22 UTC (History)
0 users

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 Sébastien Ducoulombier 2019-05-09 07:39:46 UTC
Description:
Setting AutoValue to an integer column of a new table is ignored in PostgreSQL databases.

Steps to Reproduce:
1. Connect to a PostgreSQL database
2. Create Table in Design View
3. Field name: "id"
   Field type: "Integer [ int 4 ]"
   AutoValue: "Yes"
4. Add a text field
Save to Schema "public", table name: "t"
5. Open table "t" to input data

Actual Results:
Column "id" must be filled-in.
It was created as integer not null primary key.


Expected Results:
Column "id" should show "<AutoField>" placeholder and not require user input.
It should have been created as serial primary key.
Sequence t_id_seq would have been created
and nextval('t_id_seq'::regclass) would have been set as default value.



Reproducible: Always


User Profile Reset: Yes



Additional Info:
Workaround: use Tools / SQL… or an external tool to create tables, then restart LibreOffice so it reloads database information. View / Refresh Table is not enough to get the "<AutoField>" placeholder.

Example:
create table t(id serial primary key, name varchar(100))

I can reproduce this bug using versions 5.4.0.3 and current dev build (6.3.0.0.alpha0+)

Version: 6.3.0.0.alpha0+
Build ID: 98630a0bd49bd80652145a21e4e0d0ded792b36b
CPU threads: 4; OS: Linux 4.9; UI render: default; VCL: gtk3; 
TinderBox: Linux-rpm_deb-x86_64@86-TDF, Branch:master, Time: 2019-05-04_04:44:35
Locale: fr-FR (fr_FR.UTF-8); UI-Language: en-US
Calc: threaded
Comment 1 Alex Thurgood 2019-05-13 06:22:16 UTC

*** This bug has been marked as a duplicate of bug 60643 ***