DBX master detail

dbxquery1 is an select * from data left join etc...
dbxquery2 is an select * from subdata left join etc... where id = :id

I set up the id param as data.id and the mastersource to dbxquery1

If I preview I get the error, cannot do this on a closed dataset, or if I change the create order a GPF. Fields are updated (ie no sql error). The way I solved it for now: in the beforeprintband of dbxquery1 I close dbxquery2 and open it again. This results in a correct report with again the notice that there are no sql errors otherwise this would not work.

Am i doing something wrong?

Comments

  • edited 6:11AM
    Ah, just had a clear moment: this goes only wrong if you have a 2 pass report, in the second pass it errors!
  • edited 6:11AM
    Would be good if someone could confirm this. Only designed master detail in 2 pass goes wrong with an 'cannot do this on a close dataset'. This is in the method first of the tfrxdbdataset where initialized = True but in the second pass the table is closed and therefore not is opened.

    my solution was to create a manual masterdetail en take care myself of the regfresh on 'master' skip

Leave a Comment

Rich Text Editor. To edit a paragraph's style, hit tab to get to the paragraph menu. From there you will be able to pick one style. Nothing defaults to paragraph. An inline formatting menu will show up when you select text. Hit tab to get into that menu. Some elements, such as rich link embeds, images, loading indicators, and error messages may get inserted into the editor. You may navigate to these using the arrow keys inside of the editor and delete them with the delete or backspace key.