Home JPA save BigDecimal as integer in Database
 I have this field in the database: ITEMCOST NUMERIC (13) DEFAULT 0 NOT NULL  In JAVA, the field in the Entity is defined like this: @Column(name = "ITEMCOST") private BigDecimal itemCost;  The values are stored in the database as integer. Where the last two digits are the decimal values. like this: DB 100 means 1.00 DB 250 means 2.50 etc What I want is when I read the Entity the value is loaded like that. If the value in the database is 357 the BigDeciamal should have the value "3.57". And when I save that entity, the value should be converted again as INT.