Created attachment 133517 [details] 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.
(In reply to Howard Johnson from comment #0) > The only way I have found to fix this is to delete the table and start over. No, that shouldn't be necessary, just delete the Primary Key from the table in the UI, then use an ALTER TABLE statement via the Tools > SQL menu entry : http://ooo-forums.apache.org/en/forum/viewtopic.php?f=61&t=64482#p286456 > > This is a very basic malfunction that a new Base user will likely run into. This is a well documented known limitation, as the above link shows. If you still have a problem with the auto increment function not working once you have deleted the primary key from the table, then issued the ALTER TABLE command, there might be reason to file a bug report for that.
Alex, First let me say that I very much appreciate your looking into this and all of the other work you've done on LO! But just to be clear, I did not submit this report or the others to find workarounds, but rather to provide the basis to start to fix these issues in the first place. I want Base to work better, not to have to send users looking for obscure answers related to very introductory and simple issues like renaming a field. All in all, it's pretty clear to me that we're in a pretty bad way in terms of overall LO Base maintenance. Other than that I'm not sure what to think. I've been told by a couple of guys that the LO code base is relatively very big, and complex. So it is. What in your opinion is needed to improve the overall efforts to address some of these fundamental Base issues? (FYI: I have again tried to build LO just so I could take a look at it. But I again ran into the same problem that I ran into when I first tried this, documented here: https://ask.libreoffice.org/en/question/96902/building-lo-w-mariadb-installed-fails/)
The buggy behavior is: You change the fieldname but AutoValue will be shown in the editor and wouldn't be changed to "No". When I save the table an will do View > Refresh Tables or close the database and reopen the database the AutoValue has been changed for the changed field to "No". You have only to set it back to "Yes" and save the table - works here. Two solutions for this: 1. When changing a fieldname (not deleting!) fieldtype and AutoValue shouldn't be changed. 2. When changing the fieldname and AutoValue will be changed by this command, it should be shown in the GUI of the editor. I would prefer the first solution, but could be it is a problem of the internal HSQLDB, which couldn't be changed.
** Please read this message in its entirety before responding ** To make sure we're focusing on the bugs that affect our users today, LibreOffice QA is asking bug reporters and confirmers to retest open, confirmed bugs which have not been touched for over a year. There have been thousands of bug fixes and commits since anyone checked on this bug report. During that time, it's possible that the bug has been fixed, or the details of the problem have changed. We'd really appreciate your help in getting confirmation that the bug is still present. If you have time, please do the following: Test to see if the bug is still present with the latest version of LibreOffice from https://www.libreoffice.org/download/ If the bug is present, please leave a comment that includes the information from Help - About LibreOffice. If the bug is NOT present, please set the bug's Status field to RESOLVED-WORKSFORME and leave a comment that includes the information from Help - About LibreOffice. Please DO NOT Update the version field Reply via email (please reply directly on the bug tracker) Set the bug's Status field to RESOLVED - FIXED (this status has a particular meaning that is not appropriate in this case) If you want to do more to help you can test to see if your issue is a REGRESSION. To do so: 1. Download and install oldest version of LibreOffice (usually 3.3 unless your bug pertains to a feature added after 3.3) from http://downloadarchive.documentfoundation.org/libreoffice/old/ 2. Test your bug 3. Leave a comment with your results. 4a. If the bug was present with 3.3 - set version to 'inherited from OOo'; 4b. If the bug was not present in 3.3 - add 'regression' to keyword Feel free to come ask questions or to say hello in our QA chat: https://kiwiirc.com/nextclient/irc.freenode.net/#libreoffice-qa Thank you for helping us make LibreOffice even better for everyone! Warm Regards, QA Team MassPing-UntouchedBug
I submitted the following bug which may be related. Bug 122300 - LibreOffice Base: Table Creation Wizard: Primary Key "AutoValue" does not populate after error.
Dear Howard Johnson, To make sure we're focusing on the bugs that affect our users today, LibreOffice QA is asking bug reporters and confirmers to retest open, confirmed bugs which have not been touched for over a year. There have been thousands of bug fixes and commits since anyone checked on this bug report. During that time, it's possible that the bug has been fixed, or the details of the problem have changed. We'd really appreciate your help in getting confirmation that the bug is still present. If you have time, please do the following: Test to see if the bug is still present with the latest version of LibreOffice from https://www.libreoffice.org/download/ If the bug is present, please leave a comment that includes the information from Help - About LibreOffice. If the bug is NOT present, please set the bug's Status field to RESOLVED-WORKSFORME and leave a comment that includes the information from Help - About LibreOffice. Please DO NOT Update the version field Reply via email (please reply directly on the bug tracker) Set the bug's Status field to RESOLVED - FIXED (this status has a particular meaning that is not appropriate in this case) If you want to do more to help you can test to see if your issue is a REGRESSION. To do so: 1. Download and install oldest version of LibreOffice (usually 3.3 unless your bug pertains to a feature added after 3.3) from https://downloadarchive.documentfoundation.org/libreoffice/old/ 2. Test your bug 3. Leave a comment with your results. 4a. If the bug was present with 3.3 - set version to 'inherited from OOo'; 4b. If the bug was not present in 3.3 - add 'regression' to keyword Feel free to come ask questions or to say hello in our QA chat: https://kiwiirc.com/nextclient/irc.freenode.net/#libreoffice-qa Thank you for helping us make LibreOffice even better for everyone! Warm Regards, QA Team MassPing-UntouchedBug
Dear Howard Johnson, To make sure we're focusing on the bugs that affect our users today, LibreOffice QA is asking bug reporters and confirmers to retest open, confirmed bugs which have not been touched for over a year. There have been thousands of bug fixes and commits since anyone checked on this bug report. During that time, it's possible that the bug has been fixed, or the details of the problem have changed. We'd really appreciate your help in getting confirmation that the bug is still present. If you have time, please do the following: Test to see if the bug is still present with the latest version of LibreOffice from https://www.libreoffice.org/download/ If the bug is present, please leave a comment that includes the information from Help - About LibreOffice. If the bug is NOT present, please set the bug's Status field to RESOLVED-WORKSFORME and leave a comment that includes the information from Help - About LibreOffice. Please DO NOT Update the version field Reply via email (please reply directly on the bug tracker) Set the bug's Status field to RESOLVED - FIXED (this status has a particular meaning that is not appropriate in this case) If you want to do more to help you can test to see if your issue is a REGRESSION. To do so: 1. Download and install oldest version of LibreOffice (usually 3.3 unless your bug pertains to a feature added after 3.3) from https://downloadarchive.documentfoundation.org/libreoffice/old/ 2. Test your bug 3. Leave a comment with your results. 4a. If the bug was present with 3.3 - set version to 'inherited from OOo'; 4b. If the bug was not present in 3.3 - add 'regression' to keyword Feel free to come ask questions or to say hello in our QA chat: https://web.libera.chat/?settings=#libreoffice-qa Thank you for helping us make LibreOffice even better for everyone! Warm Regards, QA Team MassPing-UntouchedBug
Bug ist still the same in LO 7.4.3.2 on OpenSUSE 15.3 64bit rpm Linux