Hibernate映射类型,对应的java基本类型及对应的标准SQL类型

Could not execute JDBC batch update; nested exception is org.hibernate.exception.DataException: Could not execute JDBC batch update


  Hibernate映射类型,对应的java基本类型及对应的标准SQL类型
      Hibernate 映射类型               java类型                     标准SQL类型
       integer或者int                  int                          INTEGER
       long                            long                         BIGINT
       short                           short                        SMALLINT
       byte                            byte                         TINYINT
       float                           float                        FLOAT
       double                          double                       DOUBLE
       big_decimal                     java.math.BigDecimal         NUMERIC
       character                       char and string              CHAR
       string                          string                       VARCHAR
       boolean                         boolean                      BIT
    
              Hibernate映射类型,对应的java时间和日期类型及对应的标准SQL类型
     映射类型           java类型                     标准SQL类型             描述
      date       java.util.Date或者java.sql.Date        DATE         代表日期,YYYY-MM-DD
      time       java.util.Date或者java.sql.Date        TIME         代表时间,形式为HH:MM:SS
      timestamp  java.util.Date或者java.sql.Timestamp   TIMESTAMP    代表日期和时间,YYYYMMDDHHMMSS
      calendar   java.util.Calendar                     TIMESTAMP    同上
   calendar_date java.util.Calendar                     DATE         代表日期,YYYY-MM-DD


6                           JAVA大对象类型的Hibernate映射类型
   映射类型             java类型                 标准SQL类型           MYSQL类型           ORALCE类型
   binary                byte[]                 VARBINARY(或BLOB)      BLOB                  BLOB
   text                  string                 CLOB                   TEXT                  CLOB
   serializable          实现Serializable       VARBINARY(或BLOB)      BLOB                  BLOB
                         接口任意一个java类
   clob                  java.sql.Clob          CLOB                   TEXT                  CLOB           
   blob                  java.sql.Blob          BLOB                   BLOB                  BLOB

你可能感兴趣的:(Hibernate)