Compartir a través de


Visual FoxPro OLE DB Provider Data Support

The following table describes the types and other file and code characteristics of data supported by the Visual FoxPro OLE DB Provider.

Data type Indicator Size Range OLE DB type
Character C 1 byte per char to 254 Any Characters DBTYPE_STR
Character (binary) C NOCPTRANS 1 byte per char to 254 Any Characters DBTYPE_BYTES
Date D 8 bytes 0001-01-01 to 9999-12-31 DBTYPE_DATE
DateTime T 8 bytes 0001-01-01 to 9999-12-31; 00:00:00 a.m. to 11:59:59 p.m. DBTYPE_DBTIMESTAMP
Numeric N 1 to 20 bytes - .9999999999E+19 to .9999999999E+20 DBTYPE_DECIMAL
Float F 1 to 20 bytes - .9999999999E+19 to .9999999999E+20 DBTYPE_DECIMAL
Integer I 4 bytes 2147483647 to 2147483647 DBTYPE_I4
Double B 8 bytes +/-4.94065645841247E-324 to +/-8.9884656743115E307 DBTYPE_R8
Currency Y 8 bytes - 922337203685477.5807 to 922337203685477.5807 DBTYPE_CY
Logical L   .T./.F. DBTYPE_BOOL
Memo M 4 bytes in table Available memory DBTYPE_BYTES
Memo (binary) M NOCPTRANS 4 bytes in table Available memory DBTYPE_BYTES
General (blob) G 4 bytes in table Available memory DBTYPE_BYTES

The following table describes the mapping of Visual FoxPro OLE DB types to Visual Studio types:

Indicator OLE DB type Visual Studio type
C DBTYPE_STR System.String
C NOCPTRANS DBTYPE_BYTES System.String
D DBTYPE_DATE System.DateTime
T DBTYPE_DBTIMESTAMP System.DateTime
N DBTYPE_NUMERIC System.Decimal
F DBTYPE_NUMERIC System.Decimal
I DBTYPE_I4 System.Int32
B DBTYPE_R8 System.Double
Y DBTYPE_CY System.Decimal
M DBTYPE_STR System.String
M NOCPTRANS DBTYPE_BYTES System.Byte
G DBTYPE_BYTES System.Byte

See Also

Language Reference for OLE DB Development | Supported Visual FoxPro SET Commands | Supported Visual FoxPro Commands and Functions | Unsupported Visual FoxPro Commands and Functions | Supported OLE DB Objects | Standard and Custom OLE DB Properties | OLE DB Provider for Visual FoxPro