OracleSparseVector(sparseVectorString, providerType)

This constructor creates an instance of the OracleSparseVector class with the string representation of a sparse vector.

Declaration

// C#
public OracleSparseVector(string sparseVectorString, OracleDbType providerType);

Parameters

  • sparseVectorString

    The string representation of a sparse vector

  • providerType

    The OracleDbType of the resulting OracleSparseVector.

Exceptions

ArgumentException - The parameter is an invalid string or binary representation of an OracleSparseVector or the providerType is not an OracleDbType.Vector*.

ArgumentNullException - The parameter is null.

Remarks

The allowed providerType values are:

  • OracleDbType.Vector

  • OracleDbType.Vector_Binary

  • OracleDbType.Vector_Int8

  • OracleDbType.Vector_Float32

  • OracleDbType.Vector_Float64

If the vector parameter has a length of zero, then the constructed instance will have null value and IsNull will be true.

When providerType is OracleDbType.Vector and if sparseVectorString is in binary sparse vector format, then the OracleSparseVector ProviderType becomes OracleDbType.Vector_Binary; otherwise, it becomes OracleDbType.Vector_Float32 for other vector formats.