MssqlServerClock enum

SQL Server clock functions and their result types.

Server time avoids differences between application and database time zones.

Inheritance
Available extensions

Values

localDateTime2 → const MssqlServerClock

SYSDATETIME(): datetime2(7) in the server's own time zone.

const MssqlServerClock('SYSDATETIME()')
utcDateTime2 → const MssqlServerClock

SYSUTCDATETIME(): datetime2(7) in UTC.

const MssqlServerClock('SYSUTCDATETIME()')
localDateTimeOffset → const MssqlServerClock

SYSDATETIMEOFFSET(): the server's now, with its offset attached.

The only one comparable with a datetimeoffset column without the server inventing an offset for the other side.

const MssqlServerClock('SYSDATETIMEOFFSET()')
localDateTime → const MssqlServerClock

GETDATE(): datetime, so 3.33 ms resolution.

const MssqlServerClock('GETDATE()')
utcDateTime → const MssqlServerClock

GETUTCDATE(): datetime in UTC.

const MssqlServerClock('GETUTCDATE()')

Properties

hashCode int
The hash code for this object.
no setterinherited
index int
A numeric identifier for the enumerated value.
no setterinherited
name String

Available on Enum, provided by the EnumName extension

The name of the enum value.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
sql String
The complete SQL function call.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Constants

values → const List<MssqlServerClock>
A constant List of the values in this enum, in order of their declaration.