Field Specifics

The Field object, as stated earlier, contains all of the information that corresponds to a single column of data within the recordset. The most important type of field characteristic is the field’s datatype.

Field Datatypes

The datatype of a field specifies the type of information stored in the field within the recordset. There are many different datatypes available from many different data sources. ADO contains a list of datatypes that encompasses the majority of the datatypes known to developers. This list is shown in Table 6-1. These values are constants that represent the different datatype values that the Type property of the Field object can be set to.

Table 6-1. The DataTypeEnum Enumeration

Value

Description

adArray

Indicates that the datatype of the Field object is a safe array of another type that is joined to the adArray value by a logical Or.

adBigInt

Indicates that the datatype of the Field object is an 8-byte signed integer value.

adBinary

Indicates that the datatype of the Field object is a binary value.

adBoolean

Indicates that the datatype of the Field object is a Boolean value.

adByRef

Indicates that the datatype of the Field object is a pointer to another type which is joined to the adByRef value by a logical Or.

adBSTR

Indicates that the datatype of the Field object is a null-terminated character-string value.

adChar

Indicates that the datatype of the Field object is a String value.

adCurrency

Indicates that the datatype of the ...

Get ADO: ActiveX Data Objects now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.