catalog="test"> <id name="id" type="java.lang.Integer"> <column name="id" /> <generator class="assigned" /> </id> <property name="name" type="java.lang.String"> <column name="name" length="45" /> </property> <property name="value" type="java.lang.String"> <column name="value" length="45" /> </property> </class> <sql-query name="queryPro1" callable="true"> <!-- alias: 查询返回的对象的别名, 随便取 class 查询返回的类的全路径,否则会抱找不到类的错误 --> <return alias="t1" class="com.test.hibernate.TableTest"> <return-property name="c1" column="id" /> <return-property name="c2" column="name" /> <return-property name="c3" column="value" /> </return> { call queryPro()} </sql-query> |