让我们改变字段!

amyfun 2000-07-20 11:54:00
用Database DeskTop的ParaDox7定义了一个L型的字段Yijie;
由UpdateSQL1的ModifySQL定义。
update "Book.DB"
set
Yijie = :Yijie
where
Suoshuhao = :OLD_Suoshuhao(Suoshuhao是主索引字段)
同时在一个Button事件中,编辑如下:
if Query2.FieldByName('Yijie').AsBoolean then
ShowMessage('该书已经借出!')
else
begin
Query2.Edit;
Query2.FieldByName('Yijie').AsBoolean:= True;
Query2.ApplyUpdates;
end;
但每次一按确定,他提示我query2:cannot modified a read-only dataset

不知为什么?
...全文
72 3 打赏 收藏 转发到动态 举报
写回复
用AI写文章
3 条回复
切换为时间正序
请发表友善的回复…
发表回复
bpc 2000-07-20
  • 打赏
  • 举报
回复
RequestLive为true;先POST;再ApplyUpdates
bpc 2000-07-20
  • 打赏
  • 举报
回复
RequestLive为true;
ymxxm 2000-07-20
  • 打赏
  • 举报
回复
QUery2的RequestLive为true;

5,388

社区成员

发帖
与我相关
我的任务
社区描述
Delphi 开发及应用
社区管理员
  • VCL组件开发及应用社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧