<PackageReference Include="System.Data.SqlClient" Version="4.7.0-preview6.19303.8" />

SqlParameter

public sealed class SqlParameter : DbParameter, ICloneable
Represents a parameter to a SqlCommand and optionally its mapping to DataSet columns. This class cannot be inherited. For more information on parameters, see Configuring Parameters and Parameter Data Types.
public SqlCompareOptions CompareInfo { get; set; }

Gets or sets the CompareInfo object that defines how string comparisons should be performed for this parameter.

public int LocaleId { get; set; }

Gets or sets the locale identifier that determines conventions and language for a particular region.

public int Offset { get; set; }

Gets or sets the offset to the Value property.

public byte Precision { get; set; }

Gets or sets the maximum number of digits used to represent the Value property.

public byte Scale { get; set; }

Gets or sets the number of decimal places to which Value is resolved.

public SqlDbType SqlDbType { get; set; }

Gets or sets the SqlDbType of the parameter.

public object SqlValue { get; set; }

Gets or sets the value of the parameter as an SQL type.

public string TypeName { get; set; }

Gets or sets the type name for a table-valued parameter.

public string UdtTypeName { get; set; }

public string XmlSchemaCollectionDatabase { get; set; }

Gets the name of the database where the schema collection for this XML instance is located.

public string XmlSchemaCollectionName { get; set; }

Gets the name of the schema collection for this XML instance.

public string XmlSchemaCollectionOwningSchema { get; set; }

The owning relational schema where the schema collection for this XML instance is located.

public SqlParameter()

Initializes a new instance of the SqlParameter class.

public SqlParameter(string parameterName, SqlDbType dbType)

Initializes a new instance of the SqlParameter class that uses the parameter name and the data type.

public SqlParameter(string parameterName, SqlDbType dbType, int size)

Initializes a new instance of the SqlParameter class that uses the parameter name, the SqlDbType, and the size.

public SqlParameter(string parameterName, SqlDbType dbType, int size, ParameterDirection direction, bool isNullable, byte precision, byte scale, string sourceColumn, DataRowVersion sourceVersion, object value)

public SqlParameter(string parameterName, SqlDbType dbType, int size, ParameterDirection direction, byte precision, byte scale, string sourceColumn, DataRowVersion sourceVersion, bool sourceColumnNullMapping, object value, string xmlSchemaCollectionDatabase, string xmlSchemaCollectionOwningSchema, string xmlSchemaCollectionName)

Initializes a new instance of the SqlParameter class that uses the parameter name, the type of the parameter, the length of the parameter the direction, the precision, the scale, the name of the source column, one of the DataRowVersion values, a Boolean for source column mapping, the value of the SqlParameter, the name of the database where the schema collection for this XML instance is located, the owning relational schema where the schema collection for this XML instance is located, and the name of the schema collection for this parameter.

public SqlParameter(string parameterName, SqlDbType dbType, int size, string sourceColumn)

Initializes a new instance of the SqlParameter class that uses the parameter name, the SqlDbType, the size, and the source column name.

public SqlParameter(string parameterName, object value)

Initializes a new instance of the SqlParameter class that uses the parameter name and a value of the new SqlParameter.

public void ResetSqlDbType()

Resets the type associated with this SqlParameter.