JDBC Types to Java Types Mapping - Java JDBC

Java examples for JDBC:JDBC Types

Introduction

Data Types Mapping Between JDBC and Java

JDBC Type Java Type
ARRAY java.sql.Array
BIGINT long
BINARY byte[]
BITboolean
BLOB java.sql.Blob
BOOLEANboolean
CHAR String
CLOB java.sql.Clob
DATALINK java.net.URL
DATE java.sql.Date
DATE java.time.LocalDate
DECIMALjava.math.BigDecimal
DISTINCT Mapping of underlying type
DOUBLEdouble
FLOAT double
INTEGER int
JAVA_OBJECT underlying Java class
LONGNVARCHAR String
LONGVARBINARY byte[]
LONGVARCHAR String
NCHAR String
NCLOB java.sql.NClob
NUMERIC java.math.BigDecimal
NVARCHAR String
REAL float
REF java.sql.Ref
REF_CURSORJava.sql.ResultSet
ROWID java.sql.RowId
SMALLINT short
SQLXMLjava.sql.SQLXML
STRUCTjava.sql.Struct
TIME java.sql.Time
TIME java.time.LocalTime
TIME_WITH_TIMEZONEjava.time.OffsetTime
TIMESTAMP java.sql.Timestamp
TIMESTAMP_WITH_TIMEZONE java.time.OffsetDateTime
TINYINT byte
VARBINARY byte[]
VARCHAR String

Related Tutorials