How do I write an expression to gain the result of 1 parameter equals another parameter by default.

I have two independent calendar report parameters, not between,  which I need to make the 2nd one always = the date on the first by default or the 2nd parameter  can be selected from the calendar independently.

Desired Default - Whatever paramA equals  paramB equals
paramA 01/01/01 = paramB 01/01/01
paramA 02/02/02 = paramB 02/02/02


ParamB independently selected
paramA 01/01/01 and paramB 02/02/02
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

rhservanAuthor Commented:
I would like this to be an expression as the "default specify value" on the parameter.
Tim HumphriesDirectorCommented:

You can only partly achieve what you want here. You can set the default for parameter B to be the value of parameter A. (i.e. parameterA.value)
When ParameterA is selected, parameter B's default value will be set to the value of ParameterA, but after that any changes to parameterA will not be reflected in parameterB - it is only the default value you can set and once a value is supplied for ParameterB you cannot change it. There is no 'onChange' event associated with parameter setting that you can tap into.


Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
ValentinoVBI ConsultantCommented:
Maybe you can handle this another way?  If you allow NULL values for Par B, and assume that NULL means "equal to Par A", all that then remains to be done is handle this at the query side.
And that can be done by using COALESCE, for instance COALESCE(@ParB, @ParA).  This would use the value of Par B when specified.  When not specified (and thus NULL), it uses the value of Par A.

Makes sense?
This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.