ssdl view and TPT

I want to do the same than my last post with TPT.

I add this in ssdl:

<EntitySet Name=Managers EntityType=TestModel1.Store.Managers>

    <DefiningQuery>

        SELECT DISTINCT EmployeeManager

        FROM EmployeesWithManager

    </DefiningQuery>

</EntitySet>


<EntityType Name=Managers>

    <Key>

        <PropertyRef Name=EmployeeManager />

    </Key>

    <Property Name=EmployeeManager Type=int Nullable=false />

</EntityType>


Then, I just need to create Manager entity type, add inheritance between it and Employee entity type, map EmployeeManager ssdl view with EmployeeId property and it’s all.


It’s too easy to use Entity Framework, isn’t it? [;)]

This entry was posted in 7671, 7674, 7675. Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *


*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>