K
Keith G Hicks
I have a system for a client where a couple of tables periodically lose
their primary key indexes and the associated FK's get blown away. We have
not been able to determine why this happens and it is very frustrating. I
decided instead to write some code that will run each time a user opens up
the front end to determine if certain PK's are still there and also test for
the related FK's. But I'm not sure how to go about that. Can anyone point me
to vba samples that check this sort of thing?
For example, I have a table called tblInvoices. The PK is on the field
InvoiceID. I want to run some vba to be sure that field is still the PK and
I also want to be sure that it's still connected to the child tables.
Thanks,
Keith
their primary key indexes and the associated FK's get blown away. We have
not been able to determine why this happens and it is very frustrating. I
decided instead to write some code that will run each time a user opens up
the front end to determine if certain PK's are still there and also test for
the related FK's. But I'm not sure how to go about that. Can anyone point me
to vba samples that check this sort of thing?
For example, I have a table called tblInvoices. The PK is on the field
InvoiceID. I want to run some vba to be sure that field is still the PK and
I also want to be sure that it's still connected to the child tables.
Thanks,
Keith