Property Variables
Variables
Gets the bind variables.
Declaration
public IDictionary<string, FieldValue> Variables { get; }
Property Value
Type | Description |
---|---|
IDictionary<String, FieldValue> | The collection of bind variables represented as IDictionary<TKey,TValue>. |
Remarks
This method returns bind variables as a dictionary with
string
keys and values of type FieldValue.
You may use it to access bind variables and set their values.
This is an alternative to using
SetVariable(String, FieldValue)
method. To set bind variable by its position, use
SetVariable(Int32, FieldValue) method.
Examples
Setting bind variables.// Setting variables of different types.
preparedStatement.Variables["$var1"] = 10;
preparedStatement.Variables["$var2"] = "abc";
preparedStatement.Variables["$var3"] = new DateTime(2021, 05, 18);