Edit

Share via


EdmFunctions.CreateDateTimeOffset Method

Definition

Creates a DbFunctionExpression that invokes the canonical 'CreateDateTimeOffset' function with the specified arguments. second must have a result type of Edm.Double, while all other arguments must have a result type of Edm.Int32. The result type of the expression is Edm.DateTimeOffset.

public:
 static System::Data::Common::CommandTrees::DbFunctionExpression ^ CreateDateTimeOffset(System::Data::Common::CommandTrees::DbExpression ^ year, System::Data::Common::CommandTrees::DbExpression ^ month, System::Data::Common::CommandTrees::DbExpression ^ day, System::Data::Common::CommandTrees::DbExpression ^ hour, System::Data::Common::CommandTrees::DbExpression ^ minute, System::Data::Common::CommandTrees::DbExpression ^ second, System::Data::Common::CommandTrees::DbExpression ^ timeZoneOffset);
public static System.Data.Common.CommandTrees.DbFunctionExpression CreateDateTimeOffset (System.Data.Common.CommandTrees.DbExpression year, System.Data.Common.CommandTrees.DbExpression month, System.Data.Common.CommandTrees.DbExpression day, System.Data.Common.CommandTrees.DbExpression hour, System.Data.Common.CommandTrees.DbExpression minute, System.Data.Common.CommandTrees.DbExpression second, System.Data.Common.CommandTrees.DbExpression timeZoneOffset);
static member CreateDateTimeOffset : System.Data.Common.CommandTrees.DbExpression * System.Data.Common.CommandTrees.DbExpression * System.Data.Common.CommandTrees.DbExpression * System.Data.Common.CommandTrees.DbExpression * System.Data.Common.CommandTrees.DbExpression * System.Data.Common.CommandTrees.DbExpression * System.Data.Common.CommandTrees.DbExpression -> System.Data.Common.CommandTrees.DbFunctionExpression
Public Function CreateDateTimeOffset (year As DbExpression, month As DbExpression, day As DbExpression, hour As DbExpression, minute As DbExpression, second As DbExpression, timeZoneOffset As DbExpression) As DbFunctionExpression

Parameters

year
DbExpression

An expression that provides the year value for the new DateTimeOffset instance.

month
DbExpression

An expression that provides the month value for the new DateTimeOffset instance.

day
DbExpression

An expression that provides the day value for the new DateTimeOffset instance.

hour
DbExpression

An expression that provides the hour value for the new DateTimeOffset instance.

minute
DbExpression

An expression that provides the minute value for the new DateTimeOffset instance.

second
DbExpression

An expression that provides the second value for the new DateTimeOffset instance.

timeZoneOffset
DbExpression

An expression that provides the number of minutes in the time zone offset value for the new DateTimeOffset instance.

Returns

A new DbFunctionExpression that returns a new DateTimeOffset based on the specified values.

Exceptions

year, month, day, hour, minute, second, or timeZoneOffset is null.

year, month, day, hour, minute, second, or timeZoneOffset is invalid.

Applies to