VistaDB 6
VistaDB.Provider Namespace / VistaDBDataReader Class / IsDBNullAsync Method / IsDBNullAsync(Int32,CancellationToken) Method
The zero-based column to be retrieved.
The cancellation instruction, which propagates a notification that operations should be canceled. This does not guarantee the cancellation. A setting of CancellationToken.None makes this method equivalent to System.Data.Common.DbDataReader.IsDBNullAsync(System.Int32). The returned task must be marked as cancelled.


In This Topic
    IsDBNullAsync(Int32,CancellationToken) Method
    In This Topic
    An asynchronous version of System.Data.Common.DbDataReader.IsDBNull(System.Int32), which gets a value that indicates whether the column contains non-existent or missing values. Optionally, sends a notification that operations should be cancelled.
    Syntax
    'Declaration
     
    
    Public Overloads Function IsDBNullAsync( _
       ByVal ordinal As System.Integer, _
       ByVal cancellationToken As System.Threading.CancellationToken _
    ) As System.Threading.Tasks.Task(Of Boolean)
    'Usage
     
    
    Dim instance As VistaDBDataReader
    Dim ordinal As System.Integer
    Dim cancellationToken As System.Threading.CancellationToken
    Dim value As System.Threading.Tasks.Task(Of Boolean)
     
    value = instance.IsDBNullAsync(ordinal, cancellationToken)
    public System.Threading.Tasks.Task<bool> IsDBNullAsync( 
       System.int ordinal,
       System.Threading.CancellationToken cancellationToken
    )

    Parameters

    ordinal
    The zero-based column to be retrieved.
    cancellationToken
    The cancellation instruction, which propagates a notification that operations should be canceled. This does not guarantee the cancellation. A setting of CancellationToken.None makes this method equivalent to System.Data.Common.DbDataReader.IsDBNullAsync(System.Int32). The returned task must be marked as cancelled.

    Return Value

    true if the specified column value is equivalent to DBNull otherwise false.
    Exceptions
    ExceptionDescription
    The connection drops or is closed during the data retrieval. -or- The System.Data.Common.DbDataReader is closed during the data retrieval. -or- There is no data ready to be read (for example, the first System.Data.Common.DbDataReader.Read hasn't been called, or returned false). -or- Trying to read a previously read column in sequential mode. -or- There was an asynchronous operation in progress. This applies to all Get* methods when running in sequential mode, as they could be called while reading a stream.
    Trying to read a column that does not exist.
    Requirements

    Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

    See Also