We help IT Professionals succeed at work.

Date as String

Hi Experts,
 Am using SAP Business Objects Web Intelligence. At present am using Report Date as Manual Prompt. here Report Date format as YYYYMMDD , I would like to consider the (today's date -1) has to go as a parameter. we have the Report Date object which has the values till 20161231. But when ever I run the report it has to take only today's date -1 in this format (YYYYMMDD).Back end is MS SQL Server.

I have tried many possibilities, but didn't work.

Thank you.
Regards,
Maruthi
Comment
Watch Question

Mike McCrackenSenior Consultant
Most Valuable Expert 2011
Top Expert 2013

Commented:
Can you make changes to the universe?

If so build a prompt in the universe that converts the date to the appropriate string format.

mlmcc
Yes. I can make changes to the Universe. I have tried changing the string to date and tried but didn't work. Am not clear on the Prompt suggestion. Why do we need prompt here.
Mike McCrackenSenior Consultant
Most Valuable Expert 2011
Top Expert 2013

Commented:
You can use a prompt for a date (can use the calendar) then in the object convert it to the string for comparison

mlmcc
Senior Consultant
Most Valuable Expert 2011
Top Expert 2013
Commented:
The filter object will be something like

[Your Date String] = FormatDate(Prompt("enter start date", "d", ,mono,constrained, non_persistent)

mlmcc
Thank you.