[Solved] Reset Autofield
[Solved] Reset Autofield
Created real simple database with one form. Used Autofield as key - did some testing, now I want to implement but Autofield is starting at 9 (tested 8 times). How do I start at 1 now that I am ready to implement?
Last edited by Hagar Delest on Mon Mar 09, 2009 12:40 am, edited 1 time in total.
Reason: tagged [Solved].
Reason: tagged [Solved].
OOo 2.3.X on MS Windows Vista
Re: Reset Autofield
Hi and welcome to the forums.
Well, you don't really need to. It'll start at 9 and do just as well as if it started at 1.
Or are you using the field as some sort of visible thing in the form as well?
Well, you don't really need to. It'll start at 9 and do just as well as if it started at 1.
Or are you using the field as some sort of visible thing in the form as well?
Ubuntu 14.10 Utopic Unicorn, LibreOffice Version: 4.3.3.2
Gurkha Welfare Trust
Gurkha Welfare Trust
-
- Volunteer
- Posts: 283
- Joined: Tue Dec 04, 2007 6:38 pm
- Location: Houston, TX
Re: Reset Autofield
you can restart it with the following SQL command
enter that command in the SQL dialog (Tools | SQL.. )
Code: Select all
ALTER TABLE <table name> ALTER COLUMN <column name> RESTART WITH <restart value>
Re: Reset Autofield
Thank you both - I guess you have a point about what difference does it make - guess I'm just being anal - on the other hand good to have the code if I can't get over it!
Thanks again
Thanks again
OOo 2.3.X on MS Windows Vista
Re: Reset Autofield
Ha ha - we're all anal about something.
If this has answered your question please go to your first post and use the edit button and add [Solved] to the start of your title. You can also select the green 'tick' icon.
If this has answered your question please go to your first post and use the edit button and add [Solved] to the start of your title. You can also select the green 'tick' icon.
Ubuntu 14.10 Utopic Unicorn, LibreOffice Version: 4.3.3.2
Gurkha Welfare Trust
Gurkha Welfare Trust