GetDateTime Method

Gets the value of the specified column as a DateTime object.

Syntax

DateTime GetDateTime( int ordinal )

Parameters

ordinal – the zero-based column ordinal.

Return Value

The value of the specified column.

Implements

IDataRecord.GetDateTime

Usage

  • No conversions are performed, so the data retrieved must already be a DateTime object.

  • Call AseDataReader.IsDBNull to check for null values before calling this method.

  • Use this method if the corresponding Adaptive Server type in the database is: datetime, smalldatetime, dateand time.

Related reference
IsDBNull Method