I defined site definition with two content types and two list definitions. I have lookup site column
<Field ID="{4318c52f-11c6-129a-b832-5ab22450b17c}"
Type="Lookup"
List="Lists/Questions"
ShowField="ID"
Name="QuestionID"
DisplayName="QuestionID"
StaticName="QuestionID"
Group="KnowledgeBase"
DisplaceOnUpgrade="TRUE"
Required="TRUE"/>
Than I use this field in Content Type
<ContentType ID="0x0100c2644b24e4ec4626be41a720171942a6"
Name="CTAnswer"
Group="Answer Content Type"
Description="Answer Conent Type"
Inherits="TRUE"
Version="0">
<FieldRefs>
<FieldRef ID="{fa542e0f-0a70-4ab9-b92c-0177e6ddd247}" Name="AnswerContent"
DisplayName="Content"/>
<FieldRef ID="{1318c52f-11c6-4b3a-b802-d0b22450b1bc}" Name="AnswerRank"
DisplayName="Rank"/>
<FieldRef ID="{4318c52f-11c6-129a-b832-5ab22450b17c}" Name="QuestionID"
DisplayName="QuestionID"/>
</FieldRefs>
</ContentType>
and after that I create List Definition based on this content type. Everything is ok, but SPMetal generates my lookups as System.Nullable, and not as EntityRef. What is wrong? Where am I mistaken?