全國最多中醫師線上諮詢網站-台灣中醫網
發文 回覆 瀏覽次數:8176
推到 Plurk!
推到 Facebook!

ADO資料集元件之CursorType和LockType屬性

 
cashxin2002
版主


發表:231
回覆:2555
積分:1937
註冊:2003-03-28

發送簡訊給我
#1 引用回覆 回覆 發表時間:2003-07-26 15:56:50 IP:63.84.xxx.xxx 未訂閱
ADO資料集元件(如ADODataSet, ADOTable, ADOQuery等)﹐其皆具有CursorType和LockType屬性﹐其中各屬性值之解釋意義如下﹕    摘自[Delphi6實務經典][林金霖]
----------------------------------------
CursorType屬性值﹕
ctUnspecified: 代表游標形態尚未指定;
ctOpenForwardOnly: 代表開啟一個只能向前的游標﹐也就是不能使用Prior操作方法將游標向后移;
ctKeyset: 代表開啟一個ctKey形態的游標﹐它表示其它使用者所做的修改并不會即時的更新客戶端的資料內容的游標形態;
ctDynamic: 代表開啟一個ctDynamic形態的游標﹐它表示其它使用者所作的修改會即時更新﹐而且可以任意操作游標;
ctStatic: 代表開啟一個STatic形態的游標﹐通常用于使用報表的制作﹐其它使用者的資料修改并不會做即時的更新﹒ LockType屬性值﹕
LtUnspecfified: 代表Lock形態尚未指定;
LtReadOnly: 代表此物件將以唯讀的方式開啟﹐因此無法執行新增﹑修改﹑刪 除等編輯功能;
LtPessimistic: 代表當資料來源的資料正在更新時﹐系統會暫時鎖住其它使用者的動作﹐以确保資料的一致性;
LtOptimistic: 代表當資料來源的資料正在更新時﹐系統不會鎖住其它使用者的動作﹐因此其它使用者同樣可以對資料進行新增﹑修改﹑刪除等編輯動作;
LtBatchOptimistic: 通常使用于批次更新作業中﹒
---------------------------------------- 努力,相信會獲得美麗!
忻晟 發表人 - cashxin2002 於 2003/07/26 16:01:35 發表人 - cashxin2002 於 2003/07/27 03:13:20
------
忻晟
編輯記錄
GrandRURU 重新編輯於 2016-06-16 16:26:52, 註解 無‧
timhuang
尊榮會員


發表:78
回覆:1815
積分:1608
註冊:2002-07-15

發送簡訊給我
#2 引用回覆 回覆 發表時間:2003-07-27 00:45:30 IP:61.62.xxx.xxx 未訂閱
Hi, 關於 LockType 的屬性值, 應該是 lt 開頭, 不是 It 開頭哦. 就像 CursorType 是 ct 開頭是一樣的!!     順便貼上在 help 中的英文說明:    CursorType :
ctUnspecified        A specific cursor type has not yet been specified.
ctOpenForwardOnly        Forward-only cursor in which you can only scroll forward; better performance because only requires single through recordset.
ctKeyset        Keyset cursor; records added by other users are not visible; records deleted by other users are inaccessible.
ctDynamic        Dynamic cursor; data modifications, deletions, and insertions by other users are visible; scrolling forward and back allowed.
ctStatic        Static cursor; static copy of records; data changes by other users not visible; used mostly for reporting.
LockType :
ltUnspecified        A specific lock type has not been specified or determined.
ltReadOnly        Read-only; the current execution cannot modify data.
ltPessimistic        Pessimistic locks; locks instantiated on a record-by-record basis when edit mode is applied to a record.
ltOptimistic        Optimistic locks; locked are initiated on a record-by-record basis, but only when updates are applied and a record is being updated.
ltBatchOptimistic        Optimistic batch updates; used for batch update mode rather than immediate update mode.
cashxin2002
版主


發表:231
回覆:2555
積分:1937
註冊:2003-03-28

發送簡訊給我
#3 引用回覆 回覆 發表時間:2003-07-27 03:09:55 IP:63.84.xxx.xxx 未訂閱
引言: Hi, 關於 LockType 的屬性值, 應該是 lt 開頭, 不是 It 開頭哦. 就像 CursorType 是 ct 開頭是一樣的!! 順便貼上在 help 中的英文說明: CursorType :
ctUnspecified        A specific cursor type has not yet been specified.
ctOpenForwardOnly        Forward-only cursor in which you can only scroll forward; better performance because only requires single through recordset.
ctKeyset        Keyset cursor; records added by other users are not visible; records deleted by other users are inaccessible.
ctDynamic        Dynamic cursor; data modifications, deletions, and insertions by other users are visible; scrolling forward and back allowed.
ctStatic        Static cursor; static copy of records; data changes by other users not visible; used mostly for reporting.
LockType :
ltUnspecified        A specific lock type has not been specified or determined.
ltReadOnly        Read-only; the current execution cannot modify data.
ltPessimistic        Pessimistic locks; locks instantiated on a record-by-record basis when edit mode is applied to a record.
ltOptimistic        Optimistic locks; locked are initiated on a record-by-record basis, but only when updates are applied and a record is being updated.
ltBatchOptimistic        Optimistic batch updates; used for batch update mode rather than immediate update mode.
謝謝timhuang前輩的指正﹒ 小弟最近好像經常筆誤... 壓力太大了﹐請各位多多見諒﹗ 已修正以上之錯誤﹒謝謝﹗ 努力,相信會獲得美麗! 忻晟
------
忻晟
領航天使
站長


發表:12216
回覆:4186
積分:4084
註冊:2001-07-25

發送簡訊給我
#4 引用回覆 回覆 發表時間:2003-07-27 09:46:12 IP:211.76.xxx.xxx 未訂閱
這裡也有站長的說明: http://delphi.ktop.com.tw/topic.php?topic_id=33369 ~~~Delphi K.Top討論區站長~~~
------
~~~Delphi K.Top討論區站長~~~
系統時間:2024-05-17 13:35:34
聯絡我們 | Delphi K.Top討論版
本站聲明
1. 本論壇為無營利行為之開放平台,所有文章都是由網友自行張貼,如牽涉到法律糾紛一切與本站無關。
2. 假如網友發表之內容涉及侵權,而損及您的利益,請立即通知版主刪除。
3. 請勿批評中華民國元首及政府或批評各政黨,是藍是綠本站無權干涉,但這裡不是政治性論壇!