Using a formula for BAQ parameter default value?

Hi Clint,
Where in the BAQ Designer did you put this expression?
I have an @ShipDate parameter that I would like the default value to be today’s date but I’m not sure how to set that default value.
Thanks for any insight you can provide,
Kelly

They don’t have a dynamic date in that screen, unfortunately. I definitely would be nice though.

So you would have to customize your dashboard to get it to make a default date.

Or (what @CSmith is doing) is make the filter equal to an expression, then use that code, so that if they don’t pass in a parameter, then use today, otherwise use what was passed in.

2 Likes

Like @Banderson said use as expression in a criteria comparison.

1 Like

Based on your image only other thing you would need to do is uncheck mandatory. I almost always use expressions for everything now to keep from introducing user errors out the gate :slight_smile:

Why not use a BAQ constant which allows you to use days, weeks, months, or years?
The value can be zero days also.

Select Days, Weeks, Months or Years

After you put in 90 days.

1 Like

Not a bad idea. I usually just setup expressions for building default values to ensure it does not error based on user input.