Oracle Tips One

          1. Do use oracle "Bind variable", it can increase the speed by 90 percent in 10g release1.

          2. Understand how to use "lock", read never block write,  vice verse.

          3. There is a side effect from oracle regarding to the "lock", if you do want to control the access to one row at a specify time (like doing an if 'this row belong to some search condition' then 'modify this row' action), you have to write some logic yourself, for example use the "for update" statement, like: "select * from x where x.id = 1 for update", so that you can lock the row only with id equals to '1' and then modify this row, so that some orther concurrence requests should execute the same sql first, yes, with the same 'for update' statement, and because you already have locked this row(id = 1), orther requests cannot get the access to it, and you get the access control to this row.

          4. Regardint to item 3, it will not decrease the concurrence level, because first you only lock the item with id equals to 1 and there maybe thousands of items in your table, second, it will not block the read request.

          posted on 2010-03-06 21:25 Find it, try it, experience it 閱讀(233) 評論(0)  編輯  收藏


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


          網站導航:
           
          <2010年3月>
          28123456
          78910111213
          14151617181920
          21222324252627
          28293031123
          45678910

          導航

          統計

          公告

          If there is any question you have, please don't hesitate, let me know ASAP, you can find me at kenees@gmail.com or QQ: 9808873, hope to make friends with you ;)

          常用鏈接

          留言簿(1)

          隨筆檔案

          文章檔案

          搜索

          積分與排名

          最新評論

          閱讀排行榜

          評論排行榜

          主站蜘蛛池模板: 江西省| 攀枝花市| 湄潭县| 阿鲁科尔沁旗| 克拉玛依市| 新闻| 武鸣县| 海兴县| 济宁市| 崇礼县| 济南市| 新和县| 林西县| 桂阳县| 丹巴县| 应用必备| 桦南县| 漾濞| 沁水县| 米泉市| 沾益县| 慈利县| 衡南县| 灌阳县| 襄城县| 磐石市| 长武县| 罗定市| 江山市| 乌鲁木齐县| 通渭县| 尉氏县| 阿拉尔市| 广州市| 谢通门县| 怀宁县| 梓潼县| 临沧市| 阜康市| 正宁县| 永济市|