BAQ Parameter from BAQ Report

Hiya,

I have a BAQ which requires the use of a Parameter in it’s Subqueries in a fairly complex way (the parameter is used within a DateDiff calculation). Is there any way to set this parameter from a BAQ Report Form?

Everything I have read so far suggests not - apparently the solution is to rewrite the BAQ without the Parameters and then define the Criteria as an “Option”? This does not seem possible in this scenario, eg:

datediff(D, SubQuery.DateField, @TO_DATE)

The BAQ uses the “@TO_DATE” Parameter in several places… all I want to do is to be able to set this from a BAQ Report!!! Surely I’m missing something?!

Any help/advice anyone can give would be greatly appreciated.

Cheers,

Steve.

If you make an RDD with BAQ reports as the datasources (as opposed to DB tables), that might work.
Make a BAQ of just your Sub-qry that needs the @TO_DATE. And another like your original BAQ (minus the Sub-qry), then do the joins between the two in the RDD.

EDIT

I take that back. That might be a way to apply a parameter to use as a filter in a sub-query. But not to pass a value used as a calculation.

1 Like
1 Like

Thank you guys!

Between @ckrusen and @hkeric.wci I was able to piece-together the solution! The main take-aways are using a BAQ as a Report Data Definition Table, and setting-up the Criteria Set and Criteria Mappings!

I still have a few little bits to iron-out - but this has been MASSIVELY helpful!

Cheers,

Steve.