setup custom date in SSRS report

I need setup custom date in my report. Right now report is running based on ORDERDATE using parameters (startdate and enddate).
In my case startdate and enddate are always the same.
What I need is create statement letting me run report based on:

If today is Monday then ORDERDATE = today-3 else if today is any other day of the week (Tue, Wed, Thu, Fri) then

Weekends (Sat, Sun) excluded.

No idea how to do that is SSRS.

thanks for help.

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.

lcohanDatabase AnalystCommented:
Please see link below and in particular "Parameter Properties - Default Values"
Use "Get values from a query" option and put the simple SQL query that will return you the needed value based on the logic you described above. I think a simple CASE structure would do it for both Start and End date.
henryk123Author Commented:
I'm pretty new with SSRS. I know how to do that in CR but SSRS is too confused for me.
Can you help with that ?

lcohanDatabase AnalystCommented:
" Right now report is running based on ORDERDATE using parameters (startdate and enddate). "
So what are you using to Edit the report? BIDS or Report Builder?
CompTIA Security+

Learn the essential functions of CompTIA Security+, which establishes the core knowledge required of any cybersecurity role and leads professionals into intermediate-level cybersecurity jobs.

henryk123Author Commented:
Report Builder.
henryk123Author Commented:
I've setup what I want use below formula:
= Iif(Weekday(Today()) = 2, DateAdd("d", -3, Today()), DateAdd("d", -1, Today()))

Technically I will run that report - Mon-Fri so I can exclude weekends that way.

I have following question:
Need add total sum from report into email subject line.
Any way to do that ?



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
henryk123Author Commented:
Figured out custom code.
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.