Sdílet prostřednictvím


EdmFunctions.CreateDateTime Metoda

Definice

Vytvoří funkci DbFunctionExpression , která vyvolá kanonickou funkci CreateDateTime se zadanými argumenty. second musí mít typ výsledku Edm.Double, zatímco všechny ostatní argumenty musí mít typ výsledku Edm.Int32. Typ výsledku výrazu je Edm.DateTime.

public:
 static System::Data::Common::CommandTrees::DbFunctionExpression ^ CreateDateTime(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);
public static System.Data.Common.CommandTrees.DbFunctionExpression CreateDateTime (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);
static member CreateDateTime : 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 CreateDateTime (year As DbExpression, month As DbExpression, day As DbExpression, hour As DbExpression, minute As DbExpression, second As DbExpression) As DbFunctionExpression

Parametry

year
DbExpression

Výraz, který poskytuje hodnotu roku pro novou instanci DateTime.

month
DbExpression

Výraz, který poskytuje hodnotu měsíce pro novou instanci DateTime.

day
DbExpression

Výraz, který poskytuje hodnotu day pro novou instanci DateTime.

hour
DbExpression

Výraz, který poskytuje hodnotu hodiny pro novou instanci DateTime.

minute
DbExpression

Výraz, který poskytuje minutovou hodnotu pro novou instanci DateTime.

second
DbExpression

Výraz, který poskytuje druhou hodnotu pro novou instanci DateTime.

Návraty

Nový DbFunctionExpression, který vrací nový DateTime na základě zadaných hodnot.

Výjimky

year, month, day, hour, minutenebo second je null.

year, month, day, hour, minutenebo second je neplatná.

Platí pro