[Solved] Cannot seem to auto-populate box in form

Creating and using forms
Post Reply
thimblerig
Posts: 3
Joined: Sat Apr 19, 2008 11:28 am

[Solved] Cannot seem to auto-populate box in form

Post by thimblerig »

My knowledge of databases is at the level of a very occasional user but I am helping to move a simple local club database from Access to Base (OOo 2.4, Win XP) even though I am completely new to Base. The membership table has come across fine and queries have been re-built. A problem has arisen however with a data input form. The current Access form auto-populates the membership number field with the next available 4-digit number whenever the form is opened or new/next record is selected. I cannot seem to replicate this functionality in Base. An SQL query of the form
SELECT MAX("Column") + 1 AS "Alias" FROM "Table"
gives me the number I need but I have not found a way of seeding either a list or combo box with this number from the query through their respective data tab. Neither entering the SQL statement direct in the "List Content" box nor referring to a simple 1-row, 1-column independent query populates the control with the number and it just remains blank when the report is opened, refreshed or next record is selected. I have the feeling I must be missing something very simple but cannot see what it is, unless I am being caught by the bug reported at viewtopic.php?f=13&t=4463. Most grateful for any help that can be given.

MWE
Last edited by thimblerig on Sun Apr 27, 2008 10:53 am, edited 1 time in total.
thimblerig
Posts: 3
Joined: Sat Apr 19, 2008 11:28 am

Re: Cannot seem to auto-populate box in form

Post by thimblerig »

Ulitmately solved the problem by working on database in Star Office 8 but not sure why. By using the SQL previously listed I can get a combo-box to increment from record to record by entering new record, saving new record and refreshing the form whereupon the combo-box has the option of the next available 4-digit number. Using OOo 2.4 on the same database I don't get the same functionality. Entering new record, saving new record and refreshing the form does not increment the number. That only happens if I include the additional step of coming out of the form and saving the whole database. Needless to say the database is going to be run on Star Office 8, free with Google Packs.

MWE
User avatar
DrewJensen
Volunteer
Posts: 1734
Joined: Sat Oct 06, 2007 9:01 pm
Location: Cumberland, MD - USA

Re: [Solved] Cannot seem to auto-populate box in form

Post by DrewJensen »

You might have a rude awakening...

the problem you are having ( if I followed your posts ) is a bug in the 2.4 code. The version of StarOffice from Google at the moment is equal to OO.o 2.3.1 - Google should be releaseing the update to 2.4 any day now...and you are going to get that bug again if you upgrade.

OO.o will be fixing the bug in the 2.4.1 release ( Scheduled for June 3 ) and then of course StarOffice via Google will follow shortly thereafter...

LOL - Damned confusing isn't it...
Former member of The Document Foundation
Former member of Apache OpenOffice PMC
LibreOffice on Ubuntu 18.04
thimblerig
Posts: 3
Joined: Sat Apr 19, 2008 11:28 am

Re: [Solved] Cannot seem to auto-populate box in form

Post by thimblerig »

Thank you for taking the time to alert me to this. While I knew that StarOffice and OOo were connected, I hadn't realised what the dependency was or its direction.

MWE
Post Reply