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

Report Parameters in SQL

edited March 2010 in Server
Is it possible to use a passed in report or session parameter in a SQL
statement?

I need the SQL to use a user specified value that will get passed to a
stored procedure to generate some totals.


Delphi 2007 / RB Server 10

Comments

  • edited March 2010

    With RB 11 you can use the Query Designer to bind search conditions to
    Report.Parameters. (Also Report.Parameters can have optional
    AutoSearchSettings).

    With RB 10 you can use Report.BeforeOpenDataPipelines event and the
    TdaSQLBuilder class to modify the SQL Search Condition at run-time. See the
    TdaSQLBuilder topic in the RBuilder help. From there you can traverse to
    subtopics that have sample code. There are also example on rbWiki

    http://www.digital-metaphors.com/rbWiki/DADE/SQLBuilder/How_To_Modify_Search_Criteria




    --
    Nard Moseley
    Digital Metaphors
    www.digital-metaphors.com


    Best regards,

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