Linking excel files to access - format changes - Type mismatch err

P

PerryK

I have 2 excel files that are linked to an access file.

Both have a column that contain "Contract Numbers" that are formated as Text
in the Excel files.

I use the contract number to link the data from these 2 files together in
access.
When I try to link them, one of the linked files formats the "Contract
Number" column as Number and the other one formats it as Text.

Because of this I get an error in my Query because the data is not the same
format.

If I import instead of linking the files, the data stays in the Text format.

Does anyone know why this happens and how it can be resolved?

The data in both files changes weekly this is why I want to link them
instead of importing them every time.
 
J

Jerry Whittle

Access makes decisions on the datatype of Excel data based on the first few
rows. As you've found out, Access can decide wrongly.

One trick is to put a bogus record in the first row with the correct type of
data.
 

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