4 writes to DataType
System.Data.Common (4)
System\Data\DataColumn.cs (2)
248
DataType
= typeof(int);
1535
clone.
DataType
= DataType;
System\Data\DataTable.cs (1)
463
dc.
DataType
= Type.GetType(typeName, throwOnError: true);
System\Data\XMLSchema.cs (1)
283
col.
DataType
= DataStorage.GetType(value);
79 references to DataType
System.Data.Common (77)
System\Data\Common\AdapterUtil.Common.cs (1)
314
return DataMapping(SR.Format(SR.ADP_ColumnSchemaMismatch, srcColumn, srcType.Name, column.ColumnName, column.
DataType
.Name));
System\Data\Common\DataColumnMapping.cs (1)
104
if ((null == dataType) || (dataType.IsArray == dataColumn.
DataType
.IsArray))
System\Data\DataColumn.cs (13)
241
if (!IsAutoIncrementType(
DataType
))
245
throw ExceptionBuilder.AutoIncrementCannotSetIfHasData(
DataType
.Name);
270
(_autoInc ??= ((
DataType
== typeof(BigInteger)) ?
604
if (
DataType
!= typeof(DateTime) && value != DataSetDateTime.UnspecifiedLocal)
681
if (newDefaultValue != DBNull.Value &&
DataType
!= typeof(object))
686
newDefaultValue = SqlConvert.ChangeTypeForDefaultValue(newDefaultValue,
DataType
, FormatProvider);
690
throw ExceptionBuilder.DefaultValueColumnDataType(ColumnName, newDefaultValue.GetType(),
DataType
, ex);
928
if ((
DataType
!= typeof(string)) && (
DataType
!= typeof(SqlString)))
1146
throw ExceptionBuilder.SetFailed(value, this,
DataType
, e);
1188
throw ExceptionBuilder.SetFailed(value!, this,
DataType
, e);
1535
clone.DataType =
DataType
;
1626
DataStorage.IsTypeCustomType(
DataType
);
System\Data\DataColumnPropertyDescriptor.cs (1)
44
public override Type PropertyType => Column.
DataType
;
System\Data\DataRelation.cs (4)
653
if ((_parentKey.ColumnsReference[i].
DataType
!= _childKey.ColumnsReference[i].
DataType
) ||
654
((_parentKey.ColumnsReference[i].
DataType
== typeof(DateTime)) &&
819
if (col.
DataType
!= typeof(int))
System\Data\DataRow.cs (1)
1199
throw ExceptionBuilder.UDTImplementsIChangeTrackingButnotIRevertible(dc.
DataType
.AssemblyQualifiedName!);
System\Data\DataTable.cs (3)
392
info.AddValue(string.Format(formatProvider, "DataTable.DataColumn_{0}.DataType_AssemblyQualifiedName", i), Columns[i].
DataType
.AssemblyQualifiedName);
3930
if (DataStorage.IsTypeCustomType(dc.
DataType
) && newValue != dc[record])
4881
DataColumn foreignKey = new DataColumn(keyName, parentKey.
DataType
, null, MappingType.Hidden);
System\Data\DataTableExtensions.cs (1)
129
table.Columns.Add(column.ColumnName, column.
DataType
);
System\Data\DataTableReader.cs (3)
517
return (_currentDataTable.Columns[ordinal].
DataType
);
799
dr[DataType] = dc.
DataType
;
801
if (dc.
DataType
== typeof(string))
System\Data\ForeignKeyConstraint.cs (3)
638
if (_parentKey.ColumnsReference[i].
DataType
!= _childKey.ColumnsReference[i].
DataType
||
639
((_parentKey.ColumnsReference[i].
DataType
== typeof(DateTime)) && (_parentKey.ColumnsReference[i].DateTimeMode != _childKey.ColumnsReference[i].DateTimeMode) && ((_parentKey.ColumnsReference[i].DateTimeMode & _childKey.ColumnsReference[i].DateTimeMode) != DataSetDateTime.Unspecified)))
System\Data\Merger.cs (3)
380
if (dest.
DataType
!= src.
DataType
||
381
((dest.
DataType
== typeof(DateTime)) && (dest.DateTimeMode != src.DateTimeMode) && ((dest.DateTimeMode & src.DateTimeMode) != DataSetDateTime.Unspecified)))
System\Data\ProviderBase\SchemaMapping.cs (4)
644
if (typeof(System.Data.SqlTypes.SqlXml) == dataColumn.
DataType
)
648
else if (typeof(System.Xml.XmlDocument) == dataColumn.
DataType
)
878
if (typeof(System.Data.SqlTypes.SqlXml) == dataColumn.
DataType
)
882
else if (typeof(System.Xml.XmlDocument) == dataColumn.
DataType
)
System\Data\Select.cs (2)
696
((isLConst && !isRConst && (leftType == StorageType.String) && (rightType == StorageType.Guid) && (null != (namedNode = expr._right as NameNode)) && (namedNode._column!.
DataType
== typeof(Guid))) ||
697
(isRConst && !isLConst && (rightType == StorageType.String) && (leftType == StorageType.Guid) && (null != (namedNode = expr._left as NameNode)) && (namedNode._column!.
DataType
== typeof(Guid))))
System\Data\TypeLimiter.cs (3)
104
/// Given a <see cref="DataTable"/>, returns all of the <see cref="DataColumn.
DataType
"/>
110
? dataTable.Columns.Cast<DataColumn>().Select(column => column.
DataType
)
115
/// Given a <see cref="DataSet"/>, returns all of the <see cref="DataColumn.
DataType
"/>
System\Data\XmlDataLoader.cs (1)
1169
!((column.
DataType
== typeof(object)) || (typeName != null) || (xsiTypeString != null));
System\Data\XMLDiffLoader.cs (2)
387
bool isPolymorphism = (column.
DataType
== typeof(object) || (row.GetAttribute(Keywords.MSD_INSTANCETYPE, Keywords.MSDNS) != null) ||
441
if (column.
DataType
== typeof(string))
System\Data\xmlsaver.cs (31)
198
string dt = XmlDataTypeName(col!.
DataType
);
199
if (bIsSqlType || (col.
DataType
== typeof(System.Numerics.BigInteger)))
201
root.SetAttribute(Keywords.MSD_DATATYPE, Keywords.MSDNS, col.
DataType
.FullName);
203
else if ((dt.Length == 0) || bImplementsInullable || ((dt == Keywords.XSD_ANYTYPE) && (col.XmlDataType != Keywords.XSD_ANYTYPE)) || (col.
DataType
== typeof(DateTimeOffset)))
210
SetMSDataAttribute(root, col.
DataType
);
1316
string typeName = XmlDataTypeName(col.
DataType
); // do not update the hashtable, as it will not write msdata:DataType
1319
if (col.
DataType
== typeof(Guid) || col.
DataType
== typeof(Type))
1327
XmlTreeGen.ValidateColumnMapping(col.
DataType
);
1338
if (col.
DataType
!= typeof(string))
1340
string dt = XmlDataTypeName(col.
DataType
);
1341
if ((col.IsSqlType && ((dt.Length == 0) || col.ImplementsINullable)) || (typeof(SqlXml) == col.
DataType
) || col.
DataType
== typeof(DateTimeOffset) || col.
DataType
== typeof(System.Numerics.BigInteger))
1343
root.SetAttribute(Keywords.MSD_DATATYPE, Keywords.MSDNS, col.
DataType
.FullName);
1352
SetMSDataAttribute(root, col.
DataType
);
1379
if (col.
DataType
== typeof(DateTime) && col.DateTimeMode != DataSetDateTime.UnspecifiedLocal)
1456
if (col.
DataType
== typeof(bool))
1460
XmlTreeGen.ValidateColumnMapping(col.
DataType
);
1468
XmlTreeGen.ValidateColumnMapping(col.
DataType
);
1471
if (col.
DataType
== typeof(bool))
1482
if (col.
DataType
== typeof(bool))
1622
if (col.
DataType
!= typeof(int))
1814
string _typeName = XmlDataTypeName(col.
DataType
);
1872
XmlTreeGen.ValidateColumnMapping(colTxt.
DataType
);
2592
if (!startElementSkipped && columnValue.GetType() != col.
DataType
)
2603
if (columnValue.GetType() != col.
DataType
)
2962
XmlTreeGen.ValidateColumnMapping(col.
DataType
);
2976
XmlTreeGen.ValidateColumnMapping(col.
DataType
);
3023
if (!startElementSkipped && valuesType != col.
DataType
)
3033
if (value.GetType() != col.
DataType
)
System.Data.Odbc (2)
src\libraries\Common\src\System\Data\ProviderBase\DbMetaDataFactory.cs (2)
213
DataColumn newDestinationColumn = new DataColumn(sourceColumn.ColumnName, sourceColumn.
DataType
);
237
if ((null == collectionNameColumn) || (typeof(string) != collectionNameColumn.
DataType
))