Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All

SqlDateTime Members

Represents the date and time data ranging in value from January 1, 1753 to December 31, 9999 to an accuracy of 3.33 milliseconds to be stored in or retrieved from a database. The SqlDateTime structure has a different underlying data structure from its corresponding .NET Framework type, DateTime, which can represent any time between 12:00:00 AM 1/1/0001 and 11:59:59 PM 12/31/9999, to the accuracy of 100 nanoseconds. SqlDateTime actually stores the relative difference to 00:00:00 AM 1/1/1900. Therefore, a conversion from "00:00:00 AM 1/1/1900" to an integer will return 0.

The following tables list the members exposed by the SqlDateTime type.

  Name Description
Public method Supported by the .NET Compact Framework SqlDateTime Overloaded. Initializes a new instance of the SqlDateTime structure.
Top

  Name Description
Public field Static Supported by the .NET Compact Framework MaxValue Represents the maximum valid date value for a SqlDateTime structure.
Public field Static Supported by the .NET Compact Framework MinValue Represents the minimum valid date value for a SqlDateTime structure.
Public field Static Supported by the .NET Compact Framework Null Represents a null value that can be assigned to the Value property of an instance of the SqlDateTime structure.
Public field Static Supported by the .NET Compact Framework SQLTicksPerHour A constant whose value is the number of ticks equivalent to one hour.
Public field Static Supported by the .NET Compact Framework SQLTicksPerMinute A constant whose value is the number of ticks equivalent to one minute.
Public field Static Supported by the .NET Compact Framework SQLTicksPerSecond A constant whose value is the number of ticks equivalent to one second.
Top

  Name Description
Public property Supported by the .NET Compact Framework DayTicks Gets the number of ticks representing the date of this SqlDateTime structure.
Public property Supported by the .NET Compact Framework IsNull Gets a value that indicates whether the Value property of the SqlDateTime structure is null.
Public property Supported by the .NET Compact Framework TimeTicks Gets the number of ticks representing the time of this SqlDateTime structure.
Public property Supported by the .NET Compact Framework Value Gets the value of the SqlDateTime structure. This property is read-only.
Top

(see also Protected Methods )
  Name Description
Public method Static Supported by the .NET Compact Framework Add Adds a SqlDateTime to the specified Timespan.
Public method Supported by the .NET Compact Framework CompareTo Overloaded. Compares this SqlDateTime structure to the supplied parameter and returns an indication of their relative values.
Public method Supported by the .NET Compact Framework Equals Overloaded. Overridden. Performs a logical comparison of two SqlDateTime structures to determine whether they are equal.
Public method Supported by the .NET Compact Framework GetHashCode Overridden. Gets the hash code for this instance.
Public method Supported by the .NET Compact Framework GetType  Gets the Type of the current instance. (Inherited from Object.)
Public method Static Supported by the .NET Compact Framework GetXsdType Returns the XML Schema definition language (XSD) of the specified XmlSchemaSet.
Public method Static Supported by the .NET Compact Framework GreaterThan Compares two instances of SqlDateTime to determine whether the first is greater than the second.
Public method Static Supported by the .NET Compact Framework GreaterThanOrEqual Compares two instances of SqlDateTime to determine whether the first is greater than or equal to the second.
Public method Static Supported by the .NET Compact Framework LessThan Compares two instances of SqlDateTime to determine whether the first is less than the second.
Public method Static Supported by the .NET Compact Framework LessThanOrEqual Compares two instances of SqlDateTime to determine whether the first is less than or equal to the second.
Public method Static Supported by the .NET Compact Framework NotEquals Performs a logical comparison of two instances of SqlDateTime to determine whether they are not equal.
Public method Static Supported by the .NET Compact Framework op_Addition Adds the period of time indicated by the supplied TimeSpan parameter, t, to the supplied SqlDateTime structure.
Public method Static Supported by the .NET Compact Framework op_Equality Performs a logical comparison of two SqlDateTime structures to determine whether they are equal.
Public method Static Supported by the .NET Compact Framework op_Explicit Overloaded. Converts a parameter to and from a SqlDateTime structure.
Public method Static Supported by the .NET Compact Framework op_GreaterThan Compares two instances of SqlDateTime to determine whether the first is greater than the second.
Public method Static Supported by the .NET Compact Framework op_GreaterThanOrEqual Compares two instances of SqlDateTime to determine whether the first is greater than or equal to the second.
Public method Static Supported by the .NET Compact Framework op_Implicit Converts a DateTime structure to a SqlDateTime structure.
Public method Static Supported by the .NET Compact Framework op_Inequality Performs a logical comparison of two instances of SqlDateTime to determine whether they are not equal.
Public method Static Supported by the .NET Compact Framework op_LessThan Compares two instances of SqlDateTime to determine whether the first is less than the second.
Public method Static Supported by the .NET Compact Framework op_LessThanOrEqual Compares two instances of SqlDateTime to determine whether the first is less than or equal to the second.
Public method Static Supported by the .NET Compact Framework op_Subtraction Subtracts the supplied TimeSpan structure, t, from the supplied SqlDateTime structure.
Public method Static Supported by the .NET Compact Framework Parse Converts the specified String representation of a date and time to its SqlDateTime equivalent.
Public method Static Supported by the .NET Compact Framework ReferenceEquals  Determines whether the specified Object instances are the same instance. (Inherited from Object.)
Public method Static Supported by the .NET Compact Framework Subtract Subtracts the specified Timespan from this SqlDateTime instance.
Public method Supported by the .NET Compact Framework ToSqlString Converts this SqlDateTime structure to SqlString.
Public method Supported by the .NET Compact Framework ToString Overridden. Converts this SqlDateTime structure to a String.
Top

  Name Description
Protected method Supported by the .NET Compact Framework Finalize  Allows an Object to attempt to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection. (Inherited from Object.)
Protected method Supported by the .NET Compact Framework MemberwiseClone  Creates a shallow copy of the current Object. (Inherited from Object.)
Top

  Name Description
Explicit interface implementation Method Supported by the .NET Compact Framework System.Xml.Serialization.IXmlSerializable.GetSchema This member supports the .NET Framework infrastructure and is not intended to be used directly from your code.
Explicit interface implementation Method Supported by the .NET Compact Framework System.Xml.Serialization.IXmlSerializable.ReadXml This member supports the .NET Framework infrastructure and is not intended to be used directly from your code.
Explicit interface implementation Method Supported by the .NET Compact Framework System.Xml.Serialization.IXmlSerializable.WriteXml This member supports the .NET Framework infrastructure and is not intended to be used directly from your code.
Top

Community Additions

ADD
Show:
© 2015 Microsoft