UPDATE queries scare me, there's too much scope for causing huge problems. I find myself with a requiremnt to use one however, and was hoping someone could help me with the following:
I have two linked tables, one with a single primary key, one with a composite primary key - one half of with is the primary key of the other table...
Table 1
ID*
Table 2
ID*
IDItem*
I want to alter the ID field once a certain criteria is met. I intend using an UPDATE query, but found that it only changed the values in one table.
I was wondering if there was a way to cascade update, so that all linked fields would be changed together, or whether the UPDATE query would have to be written so that it changes any vaues which require changing explicitly?
The thing which scares me most is losing referential integrity, so I'd appreciate some advice.
I have two linked tables, one with a single primary key, one with a composite primary key - one half of with is the primary key of the other table...
Table 1
ID*
Table 2
ID*
IDItem*
I want to alter the ID field once a certain criteria is met. I intend using an UPDATE query, but found that it only changed the values in one table.
I was wondering if there was a way to cascade update, so that all linked fields would be changed together, or whether the UPDATE query would have to be written so that it changes any vaues which require changing explicitly?
The thing which scares me most is losing referential integrity, so I'd appreciate some advice.