就是用ADOQuery,设好DataSource,然后从表的SQL为select * from detail where (master_id = :master_id) 就这样

解决方案 »

  1.   

    insert时的问题已解决,点击保存按钮时:
    1, master_table.DisableControls
    2, master_table.UpdateBatch
    3, detail_table.UpdateBatch
    4, master_table.EnableControls
    这样主表UpdateBatch时,从表就不会被refresh,删除了的数据就一直是删除状态,不会因为主表UpdateBatch而变为非删除状态但delete时的问题仍然存在,我现在唯一的解决方法是:
    1, 在master_table的BeforeDelete事件中将从表的对应数据Delete并UpdateBatch,在master_table的AfterDelete事件中,进行master_table.UpdateBatch请各位high hand想想Delete时的解决方法