ODBC and PK

B

Brian

I have several apps that use an ODBC DSN to a DB2 back-end. One table, in
particular, becomes read-only when I copy the table link from one Access DB
to another.

When I run through the Link Tables wizard (which takes a LONG time, since
there are over a hundred tables times about 50 user aliases in the DB2
schema), it asks me which field(s) contain keys, and I specify the PK. When I
then switch to design view, it correctly shows that fields as the PK.

However, when I then copy that table from one app to another, it becomes
read-only; when I switch to design view, it shows no PK.

Is there anyway to ensure that key fields remain identified as such when
copying an ODBC-based table link from one DB to another? It takes too long to
run through the Link Tables wizard every time I need to reference this table
in another application.
 
B

BeWyched

Hi Brian

I don't know about copying table links but why not re-link the tables
programatically rather than use the wizard?

Search VBA help for 'SourceTableName' and look at the DAO examples - it
should give you what you need.

Cheers.

BW
 

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

Top