Home End User
New Blog Posts: Merging Reports - Part 1 and Part 2

SQL - Data

edited November 2005 in End User
RB 9.03
In my end-user application in design mode I need to known SQL Data saved in
Report with its Query Wizard before print or preview Report..
I tried to see any events but I have no idea about it.

Vincenzo Scarpellino

Comments

  • edited November 2005

    ReportBuilder 9 includes adds a new TdaSQLBuilder class that can be used to
    modify the SQL associated with a datapipeline. There is a new
    Report.BeforeOpenDataPipelines event that can be used to modify the SQL
    prior to the datapipelines being opened/initialized by the report engine.

    See the RBuilder.hlp topic for TdaSQLBuilder for details and traverse the
    linked topics for examples.

    Here is a simple example of modifying the criteria


    lSQLBuilder := TdaSQLBuilder.Create(myDataPipeline);

    lSQLBuilder.SearchCriteria[0].Value := {some value}

    lSQLBuilder.Free;


    And here is an example from the help file...


    lSQLBuilder := TdaSQLBuilder.Create(Report.DataPipeline);

    lSQLBuilder.Clear;

    lSQLBuilder.SelectTables.Add('Customer');

    lSQLBuilder.SelectFields.AddAllFields;

    lSQLBuilder.SearchCriteria.AddAutoSearch('Customer', 'Company', 'Like',
    'S');

    lSQLBuilder.ApplyUpdates;

    lSQLBuilder.Free;







    Best regards,

    Nard Moseley
    Digital Metaphors
    www.digital-metaphors.com
This discussion has been closed.