I have 2 tables
create table Countries
(
ID bigint not null,
FullName nvarchar(255) not null unique,
constraint PK_Countries_ID primary key (ID)
)
go
create table CountryStates
(
ID bigint not null identity(1,1),
FullName nvarchar(255) not null,
ShortName nvarchar(10) null,
CountryID bigint not null,
constraint PK_CountryStates_ID primary key (ID),
constraint FK_CountryStates_CountryID foreign key (CountryID) references Countries(ID)
)
go
I need to create an Entity that has the following properties
ID (mapped to CountryStates.ID)
Fullname (mapped to CountryStates.FullName)
Shortname (mapped to CountryStates.ShortName)
CountryID (mapped to CountryStates.CountryID or COuntries.ID Whatever for the start)
CountryFullName (mapped to Countries.FullName)
link to studio screen
http://www.avwork.com/misc/MappingScreen.jpgThe error message is on the screen.
I expect the inner join to happen when selecting CountryStates.
Why does it not compile?
modified on Thursday, July 9, 2009 1:02 PM