Hi Nick,
 
If when you try to open the ODBC Mapinfo table manually you get an error
message saying that "the table you have downloaded can not be edited.." then
this can result from the table in the database not having a primary index.
But it sounds like you have got a primary key defined but that Mapinfo
cannot handle a primary key in the database which is based on more than one
field.
 
If you look in the Mapinfo_Mapcatalog table in the database the field
"spatialcolumn" identifies what I think is the primary key in the table. If
you have a look at yours, perhaps it is defining the primary key as the year
rather than both fields?
 
Whether you can edit this field to define 2 fields as the primary key is
beyond me! You could work around this by adding another field to the dbase
table based on an autonumber, add this to the primary key (ie. primary key =
year + unique id + autonumber) and just put the autonumber as the
spatialcolumn value in the Mapinfo_Mapcatalog table, and see if this works.
You may even find that this autonumber field does not need to be part of the
primary key, just indexed (I am guessing wildly here!). 
 
Or why not open the Access table directly from Mapinfo - you would still
need to define a new autonumber field though and make this indexed.
Good luck!
 
Pete, Ordnance Survey, UK.

-----Original Message-----
From: Nick Hall [mailto:[EMAIL PROTECTED]]
Sent: 08 November 1999 12:08
To: MapInfo-L
Subject: MI V5.5 & ODBC


Hi Listers,
 
I've been having problems with commits to Access from MapInfo 5.5 and
wondered if you might be able to shed any light on them...
 
I've (well, the client has) got this Access database which is being geocoded
in MapInfo. The problem seems to be that they have a concatenated primary
key in the Access table (two columns both designated as primary key). One
column is a unique integer, but the other primary key column is a year value
- in other words it's the same for all of a year's records. I can open the
table via ODBC and geocode it in MapInfo fine, but when I commit the changes
all the records get overwritten by the values for the first record.
 
If I mess about with the table in Access and set just one column as the
primary key then the commit works OK, but I won't be able to get away with
this when they give me data for more than one year.
 
Any idea if this is a feature, a bug or if I've just screwed up and I'm
using the wrong ODBC set up? I've looked through the 5.5 bug list on the
MapInfo web site, but no joy.
 
All suggestions gratefully received,
 
Nick Hall.
GIS Consultant
________________________________________________________
WARNING - THIS E-MAIL TRANSMISSION IS CONFIDENTIAL.
This e-mail transmission (including any accompanying attachments)
contains confidential information which is intended for the named 
addressee only. If you are not the intended recipient, you are hereby 
notified that any use, dissemination, distribution or reproduction of 
this e-mail is prohibited. If you have received this e-mail in error please 
contact us immediately at [EMAIL PROTECTED]
<mailto:[EMAIL PROTECTED]> . Thank you.
_________________________________________________________

----------------------------------------------------------------------
To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put
"unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]

Reply via email to