cascading updates on date field

B

Bryan

Problem:
I need to update dates in my table with another table. I can set up the
relationship, but I cannot enforce referential integrity and have cascading
updates because the date field will sometimes have empty fields in the
primary table. Therefore, I cannot index it. Any ideas of how to get around
this?
Thanks!
 
J

John Vinson

Problem:
I need to update dates in my table with another table. I can set up the
relationship, but I cannot enforce referential integrity and have cascading
updates because the date field will sometimes have empty fields in the
primary table. Therefore, I cannot index it. Any ideas of how to get around
this?
Thanks!

An Update query, joining the two tables on some other field, would
probably be better than cascading updates in any case.

You'ld join the two tables on a primary key - foreign key join, and
update TableA.Datefield to

=[TableB].[Datefield]

using the square brackets and the actual table and field names.

How are the tables related, logically?

John W. Vinson[MVP]
 
B

Bryan

John,
Thanks for the idea. It works great.

John Vinson said:
Problem:
I need to update dates in my table with another table. I can set up the
relationship, but I cannot enforce referential integrity and have cascading
updates because the date field will sometimes have empty fields in the
primary table. Therefore, I cannot index it. Any ideas of how to get around
this?
Thanks!

An Update query, joining the two tables on some other field, would
probably be better than cascading updates in any case.

You'ld join the two tables on a primary key - foreign key join, and
update TableA.Datefield to

=[TableB].[Datefield]

using the square brackets and the actual table and field names.

How are the tables related, logically?

John W. Vinson[MVP]
 
Top