send an SQL to report

edited 8:49AM in FastReport 4.0
Is that possible to send an SQL to a report at runtime instead of create an SQL in design time. I know we can send query condition values to a report at runtime. But when condition fields are varied time by time, then how can I create a whole WHERE clause at runtime to replace original SQL WHERE clause? Thank in advance!

Comments

  • gpigpi
    edited 8:49AM
    Use in Delphi's code:

    TfrxADOQuery(frxReport1.FindObject('ADOQuery1')).SQL.Text := ...
  • edited 8:49AM
    The same or similar technique that Gpi showed you can use in FR script as well as in Delphi.
    Search through this forum - there are several topics about dynamic (on-fly) changes in queries made at design time. One of them is:

    http://www.fast-report.com/en/forum/?p=/discussion/7906

    Mick

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.