[Solved] Change order of displayed records in form

Creating and using forms
Post Reply
Chichomang
Posts: 13
Joined: Mon Jan 12, 2009 7:27 pm

[Solved] Change order of displayed records in form

Post by Chichomang »

Hello -

I can't seem to figure out how to change the order in which table records are displayed in a form. I think they are being ordered by the ID# (primary key???) by default. I can choose to sort from within the form by field (Last Name), but I am trying to automate that process so that the records are displayed by Last Name as the default.

Any ideas?
Last edited by Chichomang on Wed Jan 28, 2009 6:18 pm, edited 1 time in total.
OOo 3.0.X on Ms Windows XP
User avatar
Villeroy
Volunteer
Posts: 31345
Joined: Mon Oct 08, 2007 1:35 am
Location: Germany

Re: Change order of displayed records in form

Post by Villeroy »

Right-click the form>Edit...
Get toolbar "Form Design" and call the navigator from button #5.
Get the form's properties, tab "Data"
Change content type "Table" with content "TableName" to content type "Sql" with content

Code: Select all

SELECT * FROM "TableName" ORDER BY "Last Name"
Turn off design mode (button #2 on toolbar "Form Design") and if the form works well store it into the database container and then store the database document as well.
Please, edit this topic's initial post and add "[Solved]" to the subject line if your problem has been solved.
Ubuntu 18.04 with LibreOffice 6.0, latest OpenOffice and LibreOffice
Chichomang
Posts: 13
Joined: Mon Jan 12, 2009 7:27 pm

[Solved] Re: Change order of displayed records in form

Post by Chichomang »

Thanks buddy. You're the best. Sorry it took so long to get back to you...
OOo 3.0.X on Ms Windows XP
Post Reply