DbFunctions.CreateDateTimeOffset Method (Nullable<Int32>, Nullable<Int32>, Nullable<Int32>, Nullable<Int32>, Nullable<Int32>, Nullable<Double>, Nullable<Int32>)
When used as part of a LINQ to Entities query, this method invokes the canonical CreateDateTimeOffset EDM function to create a new DateTimeOffset object.
Assembly: EntityFramework (in EntityFramework.dll)
[SuppressMessageAttribute("Microsoft.Usage", "CA1801:ReviewUnusedParameters", MessageId = "month")] [SuppressMessageAttribute("Microsoft.Usage", "CA1801:ReviewUnusedParameters", MessageId = "day")] [DbFunctionAttribute("Edm", "CreateDateTimeOffset")] [SuppressMessageAttribute("Microsoft.Usage", "CA1801:ReviewUnusedParameters", MessageId = "second")] [SuppressMessageAttribute("Microsoft.Usage", "CA1801:ReviewUnusedParameters", MessageId = "hour")] [SuppressMessageAttribute("Microsoft.Usage", "CA1801:ReviewUnusedParameters", MessageId = "minute")] [SuppressMessageAttribute("Microsoft.Usage", "CA1801:ReviewUnusedParameters", MessageId = "timeZoneOffset")] [SuppressMessageAttribute("Microsoft.Usage", "CA1801:ReviewUnusedParameters", MessageId = "year")] public static Nullable<DateTimeOffset> CreateDateTimeOffset( Nullable<int> year, Nullable<int> month, Nullable<int> day, Nullable<int> hour, Nullable<int> minute, Nullable<double> second, Nullable<int> timeZoneOffset )
Parameters
- year
-
Type:
System.Nullable<Int32>
The year.
- month
-
Type:
System.Nullable<Int32>
The month (1-based).
- day
-
Type:
System.Nullable<Int32>
The day (1-based).
- hour
-
Type:
System.Nullable<Int32>
The hours.
- minute
-
Type:
System.Nullable<Int32>
The minutes.
- second
-
Type:
System.Nullable<Double>
The seconds, including fractional parts of the seconds if desired.
- timeZoneOffset
-
Type:
System.Nullable<Int32>
The time zone offset part of the new date.
You cannot call this function directly. This function can only appear within a LINQ to Entities query. This function is translated to a corresponding function in the database.