167 references to SQL_TYPE
System.Data (167)
fx\src\data\System\Data\Odbc\DbDataRecord.cs (2)
24
internal ODBC32.
SQL_TYPE
? _dbtype;
34
internal ODBC32.
SQL_TYPE
_sql_type; // need that to properly marshal the value
fx\src\data\System\Data\Odbc\Odbc32.cs (60)
31
static internal Exception UnknownSQLType(ODBC32.
SQL_TYPE
sqltype) {
776
static private readonly TypeMap _BigInt = new TypeMap(OdbcType.BigInt, DbType.Int64, typeof(Int64), ODBC32.
SQL_TYPE
.BIGINT, ODBC32.SQL_C.SBIGINT, ODBC32.SQL_C.SBIGINT, 8, 20, true);
777
static private readonly TypeMap _Binary = new TypeMap(OdbcType.Binary, DbType.Binary, typeof(byte[]), ODBC32.
SQL_TYPE
.BINARY, ODBC32.SQL_C.BINARY, ODBC32.SQL_C.BINARY, -1, -1, false);
778
static private readonly TypeMap _Bit = new TypeMap(OdbcType.Bit, DbType.Boolean, typeof(Boolean), ODBC32.
SQL_TYPE
.BIT, ODBC32.SQL_C.BIT, ODBC32.SQL_C.BIT, 1, 1, false);
779
static internal readonly TypeMap _Char = new TypeMap(OdbcType.Char, DbType.AnsiStringFixedLength, typeof(String), ODBC32.
SQL_TYPE
.CHAR, ODBC32.SQL_C.WCHAR, ODBC32.SQL_C.CHAR, -1, -1, false);
780
static private readonly TypeMap _DateTime = new TypeMap(OdbcType.DateTime, DbType.DateTime, typeof(DateTime), ODBC32.
SQL_TYPE
.TYPE_TIMESTAMP, ODBC32.SQL_C.TYPE_TIMESTAMP, ODBC32.SQL_C.TYPE_TIMESTAMP, 16, 23, false);
781
static private readonly TypeMap _Date = new TypeMap(OdbcType.Date, DbType.Date, typeof(DateTime), ODBC32.
SQL_TYPE
.TYPE_DATE, ODBC32.SQL_C.TYPE_DATE, ODBC32.SQL_C.TYPE_DATE, 6, 10, false);
782
static private readonly TypeMap _Time = new TypeMap(OdbcType.Time, DbType.Time, typeof(TimeSpan), ODBC32.
SQL_TYPE
.TYPE_TIME, ODBC32.SQL_C.TYPE_TIME, ODBC32.SQL_C.TYPE_TIME, 6, 12, false);
783
static private readonly TypeMap _Decimal = new TypeMap(OdbcType.Decimal, DbType.Decimal, typeof(Decimal), ODBC32.
SQL_TYPE
.DECIMAL, ODBC32.SQL_C.NUMERIC, ODBC32.SQL_C.NUMERIC, 19, ADP.DecimalMaxPrecision28, false);
785
static private readonly TypeMap _Double = new TypeMap(OdbcType.Double, DbType.Double, typeof(Double), ODBC32.
SQL_TYPE
.DOUBLE, ODBC32.SQL_C.DOUBLE, ODBC32.SQL_C.DOUBLE, 8, 15, false);
786
static internal readonly TypeMap _Image = new TypeMap(OdbcType.Image, DbType.Binary, typeof(Byte[]), ODBC32.
SQL_TYPE
.LONGVARBINARY, ODBC32.SQL_C.BINARY, ODBC32.SQL_C.BINARY, -1, -1, false);
787
static private readonly TypeMap _Int = new TypeMap(OdbcType.Int, DbType.Int32, typeof(Int32), ODBC32.
SQL_TYPE
.INTEGER, ODBC32.SQL_C.SLONG, ODBC32.SQL_C.SLONG, 4, 10, true);
788
static private readonly TypeMap _NChar = new TypeMap(OdbcType.NChar, DbType.StringFixedLength, typeof(String), ODBC32.
SQL_TYPE
.WCHAR, ODBC32.SQL_C.WCHAR, ODBC32.SQL_C.WCHAR, -1, -1, false);
789
static internal readonly TypeMap _NText = new TypeMap(OdbcType.NText, DbType.String, typeof(String), ODBC32.
SQL_TYPE
.WLONGVARCHAR, ODBC32.SQL_C.WCHAR, ODBC32.SQL_C.WCHAR, -1, -1, false);
790
static private readonly TypeMap _Numeric = new TypeMap(OdbcType.Numeric, DbType.Decimal, typeof(Decimal), ODBC32.
SQL_TYPE
.NUMERIC, ODBC32.SQL_C.NUMERIC, ODBC32.SQL_C.NUMERIC, 19, ADP.DecimalMaxPrecision28, false);
791
static internal readonly TypeMap _NVarChar = new TypeMap(OdbcType.NVarChar, DbType.String, typeof(String), ODBC32.
SQL_TYPE
.WVARCHAR, ODBC32.SQL_C.WCHAR, ODBC32.SQL_C.WCHAR, -1, -1, false);
792
static private readonly TypeMap _Real = new TypeMap(OdbcType.Real, DbType.Single, typeof(Single), ODBC32.
SQL_TYPE
.REAL, ODBC32.SQL_C.REAL, ODBC32.SQL_C.REAL, 4, 7, false);
793
static private readonly TypeMap _UniqueId = new TypeMap(OdbcType.UniqueIdentifier, DbType.Guid, typeof(Guid), ODBC32.
SQL_TYPE
.GUID, ODBC32.SQL_C.GUID, ODBC32.SQL_C.GUID, 16, 36, false);
794
static private readonly TypeMap _SmallDT = new TypeMap(OdbcType.SmallDateTime, DbType.DateTime, typeof(DateTime), ODBC32.
SQL_TYPE
.TYPE_TIMESTAMP, ODBC32.SQL_C.TYPE_TIMESTAMP, ODBC32.SQL_C.TYPE_TIMESTAMP, 16, 23, false);
795
static private readonly TypeMap _SmallInt = new TypeMap(OdbcType.SmallInt, DbType.Int16, typeof(Int16), ODBC32.
SQL_TYPE
.SMALLINT, ODBC32.SQL_C.SSHORT, ODBC32.SQL_C.SSHORT, 2, 5, true);
796
static internal readonly TypeMap _Text = new TypeMap(OdbcType.Text, DbType.AnsiString, typeof(String), ODBC32.
SQL_TYPE
.LONGVARCHAR, ODBC32.SQL_C.WCHAR, ODBC32.SQL_C.CHAR, -1, -1, false);
797
static private readonly TypeMap _Timestamp = new TypeMap(OdbcType.Timestamp, DbType.Binary, typeof(Byte[]), ODBC32.
SQL_TYPE
.BINARY, ODBC32.SQL_C.BINARY, ODBC32.SQL_C.BINARY, -1, -1, false);
798
static private readonly TypeMap _TinyInt = new TypeMap(OdbcType.TinyInt, DbType.Byte, typeof(Byte), ODBC32.
SQL_TYPE
.TINYINT, ODBC32.SQL_C.UTINYINT, ODBC32.SQL_C.UTINYINT, 1, 3, true);
799
static private readonly TypeMap _VarBinary = new TypeMap(OdbcType.VarBinary, DbType.Binary, typeof(Byte[]), ODBC32.
SQL_TYPE
.VARBINARY, ODBC32.SQL_C.BINARY, ODBC32.SQL_C.BINARY, -1, -1, false);
800
static internal readonly TypeMap _VarChar = new TypeMap(OdbcType.VarChar, DbType.AnsiString, typeof(String), ODBC32.
SQL_TYPE
.VARCHAR, ODBC32.SQL_C.WCHAR, ODBC32.SQL_C.CHAR, -1, -1, false);
801
static private readonly TypeMap _Variant = new TypeMap(OdbcType.Binary, DbType.Binary, typeof(object), ODBC32.
SQL_TYPE
.SS_VARIANT, ODBC32.SQL_C.BINARY, ODBC32.SQL_C.BINARY, -1, -1, false);
802
static private readonly TypeMap _UDT = new TypeMap(OdbcType.Binary, DbType.Binary, typeof(object), ODBC32.
SQL_TYPE
.SS_UDT, ODBC32.SQL_C.BINARY, ODBC32.SQL_C.BINARY, -1, -1, false);
803
static private readonly TypeMap _XML = new TypeMap(OdbcType.Text, DbType.AnsiString, typeof(String), ODBC32.
SQL_TYPE
.LONGVARCHAR, ODBC32.SQL_C.WCHAR, ODBC32.SQL_C.CHAR, -1, -1, false);
809
internal readonly ODBC32.
SQL_TYPE
_sql_type;
818
private TypeMap(OdbcType odbcType, DbType dbType, Type type, ODBC32.
SQL_TYPE
sql_type, ODBC32.SQL_C sql_c, ODBC32.SQL_C param_sql_c, int bsize, int csize, bool signType) {
936
static internal TypeMap FromSqlType(ODBC32.
SQL_TYPE
sqltype) {
938
case ODBC32.
SQL_TYPE
.CHAR: return _Char;
939
case ODBC32.
SQL_TYPE
.VARCHAR: return _VarChar;
940
case ODBC32.
SQL_TYPE
.LONGVARCHAR: return _Text;
941
case ODBC32.
SQL_TYPE
.WCHAR: return _NChar;
942
case ODBC32.
SQL_TYPE
.WVARCHAR: return _NVarChar;
943
case ODBC32.
SQL_TYPE
.WLONGVARCHAR: return _NText;
944
case ODBC32.
SQL_TYPE
.DECIMAL: return _Decimal;
945
case ODBC32.
SQL_TYPE
.NUMERIC: return _Numeric;
946
case ODBC32.
SQL_TYPE
.SMALLINT: return _SmallInt;
947
case ODBC32.
SQL_TYPE
.INTEGER: return _Int;
948
case ODBC32.
SQL_TYPE
.REAL: return _Real;
949
case ODBC32.
SQL_TYPE
.FLOAT: return _Double;
950
case ODBC32.
SQL_TYPE
.DOUBLE: return _Double;
951
case ODBC32.
SQL_TYPE
.BIT: return _Bit;
952
case ODBC32.
SQL_TYPE
.TINYINT: return _TinyInt;
953
case ODBC32.
SQL_TYPE
.BIGINT: return _BigInt;
954
case ODBC32.
SQL_TYPE
.BINARY: return _Binary;
955
case ODBC32.
SQL_TYPE
.VARBINARY: return _VarBinary;
956
case ODBC32.
SQL_TYPE
.LONGVARBINARY: return _Image;
957
case ODBC32.
SQL_TYPE
.TYPE_DATE: return _Date;
958
case ODBC32.
SQL_TYPE
.TYPE_TIME: return _Time;
959
case ODBC32.
SQL_TYPE
.TIMESTAMP:
960
case ODBC32.
SQL_TYPE
.TYPE_TIMESTAMP: return _DateTime;
961
case ODBC32.
SQL_TYPE
.GUID: return _UniqueId;
962
case ODBC32.
SQL_TYPE
.SS_VARIANT: return _Variant;
963
case ODBC32.
SQL_TYPE
.SS_UDT: return _UDT;
964
case ODBC32.
SQL_TYPE
.SS_XML: return _XML;
966
case ODBC32.
SQL_TYPE
.SS_UTCDATETIME:
967
case ODBC32.
SQL_TYPE
.SS_TIME_EX:
fx\src\data\System\Data\Odbc\OdbcCommandBuilder.cs (1)
221
parameter.OdbcType = TypeMap.FromSqlType((ODBC32.
SQL_TYPE
)reader.GetInt16(ODBC32.DATA_TYPE-1))._odbcType;
fx\src\data\System\Data\Odbc\OdbcConnection.cs (16)
574
internal void SetSupportedType (ODBC32.
SQL_TYPE
sqltype) {
578
case ODBC32.
SQL_TYPE
.NUMERIC: {
582
case ODBC32.
SQL_TYPE
.WCHAR: {
586
case ODBC32.
SQL_TYPE
.WVARCHAR: {
590
case ODBC32.
SQL_TYPE
.WLONGVARCHAR: {
602
internal void FlagRestrictedSqlBindType(ODBC32.
SQL_TYPE
sqltype) {
606
case ODBC32.
SQL_TYPE
.NUMERIC: {
610
case ODBC32.
SQL_TYPE
.DECIMAL: {
700
internal bool TestTypeSupport (ODBC32.
SQL_TYPE
sqltype){
707
case ODBC32.
SQL_TYPE
.NUMERIC: {
712
case ODBC32.
SQL_TYPE
.WCHAR: {
717
case ODBC32.
SQL_TYPE
.WVARCHAR: {
722
case ODBC32.
SQL_TYPE
.WLONGVARCHAR: {
748
internal bool TestRestrictedSqlBindType (ODBC32.
SQL_TYPE
sqltype){
751
case ODBC32.
SQL_TYPE
.NUMERIC: {
755
case ODBC32.
SQL_TYPE
.DECIMAL: {
fx\src\data\System\Data\Odbc\OdbcDataReader.cs (34)
410
case ODBC32.
SQL_TYPE
.CHAR:
411
case ODBC32.
SQL_TYPE
.VARCHAR:
412
case ODBC32.
SQL_TYPE
.LONGVARCHAR:
413
case ODBC32.
SQL_TYPE
.WCHAR:
414
case ODBC32.
SQL_TYPE
.WVARCHAR:
415
case ODBC32.
SQL_TYPE
.WLONGVARCHAR:
418
case ODBC32.
SQL_TYPE
.DECIMAL:
419
case ODBC32.
SQL_TYPE
.NUMERIC:
422
case ODBC32.
SQL_TYPE
.SMALLINT:
425
case ODBC32.
SQL_TYPE
.INTEGER:
428
case ODBC32.
SQL_TYPE
.REAL:
431
case ODBC32.
SQL_TYPE
.FLOAT:
432
case ODBC32.
SQL_TYPE
.DOUBLE:
435
case ODBC32.
SQL_TYPE
.BIT:
438
case ODBC32.
SQL_TYPE
.TINYINT:
441
case ODBC32.
SQL_TYPE
.BIGINT:
444
case ODBC32.
SQL_TYPE
.BINARY:
445
case ODBC32.
SQL_TYPE
.VARBINARY:
446
case ODBC32.
SQL_TYPE
.LONGVARBINARY:
449
case ODBC32.
SQL_TYPE
.TYPE_DATE:
452
case ODBC32.
SQL_TYPE
.TYPE_TIME:
456
case ODBC32.
SQL_TYPE
.TYPE_TIMESTAMP:
459
case ODBC32.
SQL_TYPE
.GUID:
462
case ODBC32.
SQL_TYPE
.SS_VARIANT:
476
ODBC32.
SQL_TYPE
subtype = (ODBC32.
SQL_TYPE
)(int)GetColAttribute(i, (ODBC32.SQL_DESC)ODBC32.SQL_CA_SS.VARIANT_SQL_TYPE, (ODBC32.SQL_COLUMN)(-1), ODBC32.HANDLER.THROW);
519
info._dbtype = unchecked((ODBC32.
SQL_TYPE
)(int)GetColAttribute(i, ODBC32.SQL_DESC.CONCISE_TYPE, ODBC32.SQL_COLUMN.TYPE,ODBC32.HANDLER.THROW));
1785
typeMap = TypeMap.FromSqlType((ODBC32.
SQL_TYPE
)unchecked((int) GetColAttribute(i, ODBC32.SQL_DESC.CONCISE_TYPE, ODBC32.SQL_COLUMN.TYPE, ODBC32.HANDLER.THROW)));
1798
case ODBC32.
SQL_TYPE
.WCHAR:
1799
case ODBC32.
SQL_TYPE
.WLONGVARCHAR:
1800
case ODBC32.
SQL_TYPE
.WVARCHAR:
1815
case ODBC32.
SQL_TYPE
.LONGVARCHAR:
1816
case ODBC32.
SQL_TYPE
.WLONGVARCHAR:
1817
case ODBC32.
SQL_TYPE
.LONGVARBINARY:
fx\src\data\System\Data\Odbc\odbcmetadatafactory.cs (33)
242
ODBC32.
SQL_TYPE
sqlType;
247
sqlType = (ODBC32.
SQL_TYPE
)(Int32) Convert.ChangeType(getTypeInfoValues[indexDATA_TYPE],
254
sqlType = ODBC32.
SQL_TYPE
.TYPE_DATE;
257
sqlType = ODBC32.
SQL_TYPE
.TYPE_TIME;
280
case ODBC32.
SQL_TYPE
.LONGVARCHAR:
281
case ODBC32.
SQL_TYPE
.WLONGVARCHAR:
282
case ODBC32.
SQL_TYPE
.LONGVARBINARY:
283
case ODBC32.
SQL_TYPE
.SS_XML:
288
case ODBC32.
SQL_TYPE
.VARCHAR:
289
case ODBC32.
SQL_TYPE
.WVARCHAR:
290
case ODBC32.
SQL_TYPE
.VARBINARY:
295
case ODBC32.
SQL_TYPE
.CHAR:
296
case ODBC32.
SQL_TYPE
.WCHAR:
297
case ODBC32.
SQL_TYPE
.DECIMAL:
298
case ODBC32.
SQL_TYPE
.NUMERIC:
299
case ODBC32.
SQL_TYPE
.SMALLINT:
300
case ODBC32.
SQL_TYPE
.INTEGER:
301
case ODBC32.
SQL_TYPE
.REAL:
302
case ODBC32.
SQL_TYPE
.FLOAT:
303
case ODBC32.
SQL_TYPE
.DOUBLE:
304
case ODBC32.
SQL_TYPE
.BIT:
305
case ODBC32.
SQL_TYPE
.TINYINT:
306
case ODBC32.
SQL_TYPE
.BIGINT:
307
case ODBC32.
SQL_TYPE
.TYPE_DATE:
308
case ODBC32.
SQL_TYPE
.TYPE_TIME:
309
case ODBC32.
SQL_TYPE
.TIMESTAMP:
310
case ODBC32.
SQL_TYPE
.TYPE_TIMESTAMP:
311
case ODBC32.
SQL_TYPE
.GUID:
312
case ODBC32.
SQL_TYPE
.SS_VARIANT:
313
case ODBC32.
SQL_TYPE
.SS_UTCDATETIME:
314
case ODBC32.
SQL_TYPE
.SS_TIME_EX:
315
case ODBC32.
SQL_TYPE
.BINARY:
320
case ODBC32.
SQL_TYPE
.SS_UDT:
fx\src\data\System\Data\Odbc\OdbcParameter.cs (20)
58
private ODBC32.
SQL_TYPE
_boundParameterType; // if we bound already that is the type we used
335
if ((ODBC32.
SQL_TYPE
.CHAR == _bindtype._sql_type)
336
|| (ODBC32.
SQL_TYPE
.VARCHAR == _bindtype._sql_type)
337
|| (ODBC32.
SQL_TYPE
.LONGVARCHAR == _bindtype._sql_type)) {
347
if ((ODBC32.
SQL_TYPE
.CHAR == _bindtype._sql_type)
348
|| (ODBC32.
SQL_TYPE
.VARCHAR == _bindtype._sql_type)
349
|| (ODBC32.
SQL_TYPE
.LONGVARCHAR == _bindtype._sql_type)) {
586
case ODBC32.
SQL_TYPE
.DECIMAL:
587
case ODBC32.
SQL_TYPE
.NUMERIC:
590
|| !command.Connection.TestTypeSupport(ODBC32.
SQL_TYPE
.NUMERIC) // otherwise we convert if the driver does not support numeric
603
case ODBC32.
SQL_TYPE
.BIGINT:
615
case ODBC32.
SQL_TYPE
.WCHAR: // MDAC 68993
616
case ODBC32.
SQL_TYPE
.WVARCHAR:
617
case ODBC32.
SQL_TYPE
.WLONGVARCHAR:
626
if (ODBC32.
SQL_TYPE
.WCHAR == _bindtype._sql_type) { _bindtype = TypeMap._Char; }
627
else if (ODBC32.
SQL_TYPE
.WVARCHAR == _bindtype._sql_type) { _bindtype = TypeMap._VarChar; }
628
else if (ODBC32.
SQL_TYPE
.WLONGVARCHAR == _bindtype._sql_type) {
660
case ODBC32.
SQL_TYPE
.VARBINARY:
666
case ODBC32.
SQL_TYPE
.VARCHAR:
672
case ODBC32.
SQL_TYPE
.WVARCHAR:
fx\src\data\System\Data\Odbc\OdbcStatementHandle.cs (1)
86
internal ODBC32.RetCode BindParameter(short ordinal, short parameterDirection, ODBC32.SQL_C sqlctype, ODBC32.
SQL_TYPE
sqltype, IntPtr cchSize, IntPtr scale, HandleRef buffer, IntPtr bufferLength, HandleRef intbuffer) {