Jump to content
Server Maintenance This Week. ×

Adding a new field and data to a prexisting db


This topic is 7360 days old. Please don't post here. Open a new topic instead.

Recommended Posts

  • Newbies

I have a database I've been using for several months, it has several hundred records. I now need each record to have a unique ID so Iwant to add a new field to this database. However, I need to generate a unique numberical ID for all of the prexisting records. How do I do so? For that matter, how do I auto generate new numbers when new records are added. Thanks!

Link to comment
Share on other sites

David, first backup your current database, in case anything goes wrong.

Create the new field for your ID, and place it in a layout.

Find all the records you want to insert the data into, perhaps all.

Place the first number in the field, then go to the records menu and select replace contents, there you will find a selection to increment the number. This function works on the found set.

To automatically insert future numbers select the options for this fields definition and choose auto enter from there you can insert the last number you entered with the replce contents, then new records will automatically be entered and indexed.

Rod

Link to comment
Share on other sites

If you haven't done this yet, also make this field unmodifiable (checkbox in Define Fields > Options). That way your unique ID won't get messed up if people do finds off this field and forget they're in Browse mode.

Link to comment
Share on other sites

This topic is 7360 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.