EdmFunctions.DiffHours(DbExpression, DbExpression) Méthode

Définition

Crée une DbFunctionExpression appelant la fonction « DiffHours » canonique avec les arguments spécifiés, qui doivent tous avoir un résultat de type DateTime ou DateTimeOffset ou Time. Le résultat de l’expression est de type Edm.Int32.

public:
[System::Runtime::CompilerServices::Extension]
 static System::Data::Common::CommandTrees::DbFunctionExpression ^ DiffHours(System::Data::Common::CommandTrees::DbExpression ^ timeValue1, System::Data::Common::CommandTrees::DbExpression ^ timeValue2);
public static System.Data.Common.CommandTrees.DbFunctionExpression DiffHours (this System.Data.Common.CommandTrees.DbExpression timeValue1, System.Data.Common.CommandTrees.DbExpression timeValue2);
static member DiffHours : System.Data.Common.CommandTrees.DbExpression * System.Data.Common.CommandTrees.DbExpression -> System.Data.Common.CommandTrees.DbFunctionExpression
<Extension()>
Public Function DiffHours (timeValue1 As DbExpression, timeValue2 As DbExpression) As DbFunctionExpression

Paramètres

timeValue1
DbExpression

Expression qui spécifie le premier argument de la valeur d'heure.

timeValue2
DbExpression

Expression qui spécifie le second argument de la valeur horaire.

Retours

Nouvelle DbFunctionExpression qui retourne le nombre d’heures qui correspond à la différence entre timeValue1 et timeValue2.

S’applique à