Class JDBCDataValue
java.lang.Object
org.odpi.openmetadata.adapters.connectors.resource.jdbc.properties.JDBCDataValue
JDBCDataValue is used when inserting new rows into a table.
-
Constructor Summary
ConstructorDescriptionJDBCDataValue
(Object dataValue, int targetSQLType) Typical constructor does not need the scaleOrLength.JDBCDataValue
(Object dataValue, int targetSQLType, int scaleOrLength) Constructor for numbers and streams.JDBCDataValue
(JDBCDataValue template) Copy/clone Constructor. -
Method Summary
-
Constructor Details
-
JDBCDataValue
Typical constructor does not need the scaleOrLength.- Parameters:
dataValue
- data value formatted into an appropriate SQL typetargetSQLType
- type of the data value from java.sql.Types
-
JDBCDataValue
Constructor for numbers and streams.- Parameters:
dataValue
- data value formatted into an appropriate SQL typetargetSQLType
- type of the data value from java.sql.TypesscaleOrLength
- for java.sql.Types.DECIMAL or java.sql.Types.NUMERIC types, this is the number of digits after the decimal point. For Java Object types InputStream and Reader, this is the length of the data in the stream or reader. For all other types, this value will be ignored.
-
JDBCDataValue
Copy/clone Constructor.- Parameters:
template
- object ot copy
-
-
Method Details
-
getDataValue
The value formatted into the appropriate SQL type.- Returns:
- object
-
getTargetSQLType
public int getTargetSQLType()The type of the data value using the values from java.sql.Types.- Returns:
- int
-
getScaleOrLength
public int getScaleOrLength()Return the scaleOrLength. For java.sql.Types.DECIMAL or java.sql.Types.NUMERIC types, this is the number of digits after the decimal point. For Java Object types InputStream and Reader, this is the length of the data in the stream or reader. For all other types, this value will be ignored.- Returns:
- int
-
toString
-
equals
-
hashCode
public int hashCode()
-