W
wanxin
Unregistered / Unconfirmed
GUEST, unregistred user!
QueryBugNote.Close;
QueryBugNote.SQL.Clear;
QueryBugNote.SQL.Add('Select Bug.IdFbPatrolMan,Bug.FbName,bug.DtDisCover,bug.DtClear,bug.BugClass,bug.BugType,bug.BugText,SB_JCTZ.sbmc');
QueryBugNote.SQL.Add('From Bug,Sb_jctz,Relation');
QueryBugNote.SQL.Add(Format('Where Relation.idBlank='+'''%s''',[Fpassword.Idcorp_c+inttostr(TreeViewStationBlank.Items[0].item.ImageIndex)+inttostr(TreeViewStationBlank.Items[0].item.Item[j].ImageIndex)]));
QueryBugNote.SQl.Add('and Bug.WyBm=Sb_jctz.WYBM');
QueryBugNote.SQL.Add('and Bug.WyBm=Relation.Wybm');
QueryBugNote.Open;
//上sql
//下删除
Fdata.QueryBuGNote.ReQuestLive:=true;
Fdata.QueryBugNote.DisableControls;
FData.QueryBugNote.Delete;
Fdata.QueryBugNote.EnableControls;
出现错误,请修改最好不用sql语句进行删除.
QueryBugNote.SQL.Clear;
QueryBugNote.SQL.Add('Select Bug.IdFbPatrolMan,Bug.FbName,bug.DtDisCover,bug.DtClear,bug.BugClass,bug.BugType,bug.BugText,SB_JCTZ.sbmc');
QueryBugNote.SQL.Add('From Bug,Sb_jctz,Relation');
QueryBugNote.SQL.Add(Format('Where Relation.idBlank='+'''%s''',[Fpassword.Idcorp_c+inttostr(TreeViewStationBlank.Items[0].item.ImageIndex)+inttostr(TreeViewStationBlank.Items[0].item.Item[j].ImageIndex)]));
QueryBugNote.SQl.Add('and Bug.WyBm=Sb_jctz.WYBM');
QueryBugNote.SQL.Add('and Bug.WyBm=Relation.Wybm');
QueryBugNote.Open;
//上sql
//下删除
Fdata.QueryBuGNote.ReQuestLive:=true;
Fdata.QueryBugNote.DisableControls;
FData.QueryBugNote.Delete;
Fdata.QueryBugNote.EnableControls;
出现错误,请修改最好不用sql语句进行删除.