This project is read-only.

Named Type Constructor

Used to create instances of conceptual model nominal types such as Entity or Complex types.

Syntax

[{identifier. }] identifier( [expression [as identifier] [{, expression [as property]}] ] )

Arguments

identifier: Value that is a simple or quoted identifier.
expression: Attributes of the type that are assumed to be in the same order as they appear in the declaration of the type.
property: Name of the property to assigned value.

Return Value

Instances of named entity types.

Examples

var employeeId = 12345678;
var esql = "NorthwindDemo.Person(123, 'mike' as FirstName, 'mak' as LastName)";
var person = db.CreateQuery<NorthwindDemo.Person>(esql, employeeId).Single();
Same As
var person = new Person(123);
person.FirstName = "mike";
person.LastName = "mak";

Last edited Mar 13, 2013 at 8:40 AM by ansiboy, version 1

Comments

No comments yet.