L2008 Primary/FK error

B

bringmewater

DEV1.VSD : error L2008: 'ObservedData.StationID' : Column has same
conceptual name as column 'Station.StationId', but has a different data
type.

The PK field is StationID and is set to 'uniqueidentifier'
The FK is also Station and is set to 'int'


Why do I get this error please. I want to have the PK and FK names the
same.

Thanks !!!
 
A

Antje Kaiser

Hello,

I think an int and an uniqueidentifier isn't the same. You should set the PK
field to 'int identity' and the FK to 'int'. Set identity by choosing the
Datatype tab in the column Properties and select 'Edit'. In the following
window you will see the identity check down left.
Yours Antje
 

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