[Libreoffice-bugs] [Bug 108058] New: After renaming Primary Key AutoValue feature fails
bugzilla-daemon at bugs.documentfoundation.org
bugzilla-daemon at bugs.documentfoundation.org
Wed May 24 14:14:14 UTC 2017
https://bugs.documentfoundation.org/show_bug.cgi?id=108058
Bug ID: 108058
Summary: After renaming Primary Key AutoValue feature fails
Product: LibreOffice
Version: 5.3.3.2 release
Hardware: All
OS: All
Status: UNCONFIRMED
Severity: normal
Priority: medium
Component: Base
Assignee: libreoffice-bugs at lists.freedesktop.org
Reporter: BridgeportContractor at gmail.com
Created attachment 133517
--> https://bugs.documentfoundation.org/attachment.cgi?id=133517&action=edit
screen shot with table and error message
In a simple table after renaming the Primary Key the AutoValue feature fails
when trying to insert a new record. Error message is "Error inserting the new
rocord", and "Attempt to insert null into a non-nullable column: column: ID2
table: Table1 in statement [INSERT INTO "Table1" ("text") VALUES (?)]"
How to recreate this:
Step 1 create a simple table:
Open LibreOffice and select:
File
New
Database
* Create a new database
Select: HSQLDB Embedded
Next>>
Select either:
* No, do not register the database, OR
* Yes, ...
Click Finish
Click Save
Then select: Create a Table in Design View...
On line 1 enter: Field Name = "ID" | Field Type = "Integer"
On line 2 enter: Fidld Name = "Test" | Field Type = "Text"
Right click on green arrow left of ID and select Primary Key
Below set AutoValue to Yes
Close the window
Do you want to save the changes? Save to table name "Table1".
Click Yes
Step 2 test the table:
Double click on "Table1" to open it.
Type something in text and hit return.
ID becomes "0".
If you do this again ID becomes "1".
Step 3 edit the table and rename the primary key:
Now close the table.
Right click on "Table 1" and select "Edit".
Rename "ID" to "ID2".
Close the design and save.
Step 4 test the table again:
Again click on "Table1" to open it.
on line#2 type something in the text field and hit enter.
Expected result is that ID2 increments to the next value.
Result is the attached error message.
The only way I have found to fix this is to delete the table and start over.
This is a very basic malfunction that a new Base user will likely run into. I
ran into this when I first started using base and it made me feel like Base was
probably a pile of junk. I know better now, but this issue is still not
resolved and I just ran into it again myself a few days ago.
Thanks for looking into this.
--
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/20170524/5b93b635/attachment.html>
More information about the Libreoffice-bugs
mailing list