changed stations IDs but want to keep old station Ids in DB

W

water

I have put together a water quality database. I have one table that shows
alls the characteristics of my water quality stations (name, location,
description, lat, long etc...). For example one station name (or ID) was PR-1.
Another table that is linked to the station table through the station ID,
holds all the actual water quality data collected from the lab with a date
stamp, time stamp, parameter, water quality station ID, value and flag.

Recently, we have reviewed our nomenclature for naming water quality
stations and the stations were renamed, so PR-1 might be HSC_U now. I want to
add the new IDs in the database but I also want to preserve the old ones. I
want to be able to call the entire recordset for a given station whether I
use the old name or the new name. What is the best way to do this?

Thanks

Esther
 
J

Joan Wild

water said:
I have put together a water quality database. I have one table that
shows alls the characteristics of my water quality stations (name,
location, description, lat, long etc...). For example one station
name (or ID) was PR-1. Another table that is linked to the station
table through the station ID, holds all the actual water quality data
collected from the lab with a date stamp, time stamp, parameter,
water quality station ID, value and flag.

Recently, we have reviewed our nomenclature for naming water quality
stations and the stations were renamed, so PR-1 might be HSC_U now. I
want to add the new IDs in the database but I also want to preserve
the old ones. I want to be able to call the entire recordset for a
given station whether I use the old name or the new name. What is the
best way to do this?

I would create a new field in your table called OrigName. Run an update
query to update this field with the Name field (hope you didn't call it
Name).

If you have Cascade Update checked for the relationship between Station Id
to the foreign key in 'other table' then you can run an update query to
update PR-1 to HSC_U.

You would of course, backup before doing any updates!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Union Query 0
Multi Record Form 1
Gathering information 7
New to Access & DB's 1
Access ID 3
Recordset - query with user-entered criteria 1
normalizing and creating fields or related tables 0
Maintenance Log 1

Top