Unique index on linked table

  • Thread starter Thread starter Ron Hinds
  • Start date Start date
R

Ron Hinds

Well actually it's a SQL Server View, but Access treats them as tables,
anyway. Here's my problem: I have a SQL statement that is UPDATEing a local
Access table with data from a SQL Server view. When I initially linked the
view, Access prompted me to choose a unique field, which I did. Everything
was fine until the first time I re-linked (in code) to the production server
(DSN-less connection). When relinking in this manner, you aren't prompted
for any unique fields. So now when I run the SQL statement, I get an Access
error "Operation must use an updateable query" - even though I'm not
updating any fields in the view, only the local table. So, the question is:
1) Is there a way to define an index on the view when I'm relinking in code;
or 2) Is there another way around this? TIA!
 
You ever done this with ADOX code? I have the same issue, but am trying not
to use DAO code any more since MS said that is going away at some point. I
really am trying to embrace the future, even though it is more of a pain...
Any word on the future of DAO?

Thanks,
Chris
 
Don't believe it.

ADO has actually been replaced already (by ADO.Net)

DAO is actually still the preferred method to work with Jet databases (i.e.
..MDB files)
 

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

Back
Top