Last week, we had the author of TDD for a Shopping Website LiveProject. Friday at 11am Ranch time, Steven Solomon will be hosting a live TDD session just for us. See for the agenda and registration link
I am not an expert in hibernate but I can give you an overview to start the discussion :-)
Hibernate is an ORM framework. It will map your java objects to database relations. Each database supports its own set of data types. In java , the properties can be of any type from primitives (int, long) to Date, String ...etc. While persisting the java object in the database, hibernate has to know which datatype (DB datatype) should be used for a particular column (like varchar, int..etc).
Hibernate datatype acts as a bridge between java types and DB datatypes. Based on the database dialect , it will choose the correct datatype while creating the tables.
We use hibernate datatypes while creating hibernate mapping files (*.hbm.xml). For example, in the below code snippet, the type="string" is a hibernate type. (not that is all small , unlike java String type). Based on database we use, hibernate will map this "name" property to varchar or something similar.
Right Mr. Reddy Prashanth. But what if i change the type of your User class id as int which is a java type or for that matter if i type of property name as String in the following mapping file.
I don't think the Hibernate system would show any error .Why so?