Hibernate query

          1. session.createSqlQuery(), in purpose to increase performance, execute sql directly. addScalar() method is used to sepcify type of columns, add entity to return certain entity instance.
          2. session.getNamedQuery(), execute query defined in mapping files with <sql-query> element, the query can be a defined sql sentence or a procedure, property type and entity type can also be specifid by certain elment.
          3. update, detelet, insert sql can be defined in xml mapping files also.


          The finaly purpose of the query is to enchance performance.

          posted on 2007-05-24 12:51 Sheldon Sun 閱讀(334) 評論(0)  編輯  收藏


          只有注冊用戶登錄后才能發表評論。


          網站導航:
           
          <2007年5月>
          293012345
          6789101112
          13141516171819
          20212223242526
          272829303112
          3456789

          導航

          統計

          常用鏈接

          留言簿(3)

          隨筆檔案

          文章檔案

          搜索

          最新評論

          閱讀排行榜

          評論排行榜

          主站蜘蛛池模板: 荥阳市| 玉田县| 宿松县| 磐石市| 祁连县| 光泽县| 太康县| 柞水县| 孟村| 射洪县| 桂平市| 内乡县| 抚远县| 平顺县| 邻水| 宜阳县| 明水县| 桃园县| 即墨市| 延边| 胶南市| 都兰县| 罗定市| 怀仁县| 花垣县| 吐鲁番市| 闵行区| 澄迈县| 甘泉县| 巴楚县| 保德县| 太谷县| 柘荣县| 封开县| 仲巴县| 资源县| 厦门市| 宿松县| 津南区| 石林| 三穗县|