EdmFunctions.DiffMonths(DbExpression, DbExpression) Méthode
Définition
Important
Certaines informations portent sur la préversion du produit qui est susceptible d’être en grande partie modifiée avant sa publication. Microsoft exclut toute garantie, expresse ou implicite, concernant les informations fournies ici.
Crée un DbFunctionExpression qui appelle la fonction « DiffMonths » canonique avec les arguments spécifiés, qui doivent chacun avoir le type de résultat DateTime ou DateTimeOffset. Le type de résultat de l’expression est Edm.Int32.
public:
[System::Runtime::CompilerServices::Extension]
static System::Data::Common::CommandTrees::DbFunctionExpression ^ DiffMonths(System::Data::Common::CommandTrees::DbExpression ^ dateValue1, System::Data::Common::CommandTrees::DbExpression ^ dateValue2);
public static System.Data.Common.CommandTrees.DbFunctionExpression DiffMonths(this System.Data.Common.CommandTrees.DbExpression dateValue1, System.Data.Common.CommandTrees.DbExpression dateValue2);
static member DiffMonths : System.Data.Common.CommandTrees.DbExpression * System.Data.Common.CommandTrees.DbExpression -> System.Data.Common.CommandTrees.DbFunctionExpression
<Extension()>
Public Function DiffMonths (dateValue1 As DbExpression, dateValue2 As DbExpression) As DbFunctionExpression
Paramètres
- dateValue1
- DbExpression
Expression qui spécifie le premier argument de valeur de date.
- dateValue2
- DbExpression
Expression qui spécifie le deuxième argument de valeur de date.
Retours
Nouvelle DbFunctionExpression qui retourne le nombre de mois qui correspond à la différence entre dateValue1 et dateValue2.