RB 11 includes a major update to DADE, designed to provide more power and flexibility in building queries, linking queries, and binding to parameters.
Use the new SQL Parameter support to bind SQL Search Criteria to Report Parameters - including manually edited SQL. This enables multiple SQL DataViews to be bound to a single Parameter. Then use RB 11's enhanced Parameter architecture to configure Parameter autosearch and lookup options.
Use the QueryDesigner's search and group search pages to bind criteria to parameters.
Use the SQL Editor to manually edit that is bound to report parameters via the :ParamName notation.
Use the new SQL Group Search Criteria (ie. Having clause) support to apply search criteria to summary calculations that appear in the SQL Group By. Group Search Criteria includes support for AutoSearch and for binding to Parameters.
At design-time, use the Query Designer's new Group Search page to add group search criteria.
<screen shot of query designer search group page>
At run-time use the SQLBuilder.GroupSearchCriteria list object.
uses
SQLBuilder;
var
lSQLBuilder: TdaSQLBuilder;
begin
lSQLBuilder := TdaSQLBuilder.Create(myReport.DataPipeline);
lSQLBuilder.GroupSearchCriteria.Add('orders', 'SUM_orders_AmountPaid', '<', '50000');
// or add autosearch criteria
//lSQLBuilder.GroupSearchCriteria.AddAutoSearch('orders', 'SUM_orders_AmountPaid', '<', '50000');
lSQLBuilder.ApplyUpdates;
end;Use the new SQL Text Editor with syntax highlight support to manually edit SQL.
Implement Parameter and AutoSearch support by specifying :ParamName references to bind SQL to Report.Parameters. (see section on new Parameter and AutoSearch features).
Use Visual Linking to specify linking relationships with other SQL DataViews. Use the Link dialog's new SQL page to configure the linking options. (see section on new LInking features)
Use RB 11's enhanced Visual Linking to control how linking is implemented for individual relationships and to define linking relationships that were previously not supported - such as linking to SQL DataViews containing manually edited SQL and linking on fields that contain calc expressions.
<screen shot>
Use the new SQL page of the Link dialog to configure the SQL LinkType.
| Value | Meaning |
| ltMagicSQL | detail query fires once for entire report datapipelines are linked magic SQL is generated to support the traversal logic |
| ltParmeterizedSQL | detail query fires each time master record position changes datasets are linke d parameterized SQL is generated to linke to a master field |
| ltManualSQL | detail query fires once for entir report datapipelines are linked no generation, detail SQL must be ordered on linking field(s) |
Linking restrictions: