on 12-03-2013 7:26 PM
Hi,
Can I use the @prompt function to set a default date in the date prompts? Or Dynamic dates
IDT 4.0
Thanks
Veena
Thanks for your help! I have the syntax below. It works fine, but how do I display the "date" and not "7 days" in the prompt?
calendar.date BETWEEN (Case WHEN @Prompt(' From Dt:','A',,Mono,Free,Persistent,{'7 Days'})='7 Days' then CONVERT (VARCHAR ( 30), dateadd (day ,-7, getdate ()),101 )
ELSE @Prompt(' From Dt:','A',,Mono,Free,Persistent,{'7 Days'}) END)
AND
(Case WHEN @Prompt('To Dt:','A',,Mono,Free,Persistent,{'Today'})='Today' then CONVERT(VARCHAR(30),GETDATE(),101)
ELSE @Prompt('To Dt:','A',,Mono,Free,Persistent,{'Today'}) END)
Thank You
Veena
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Veena,
You should read the blog carefully that I suggested earlier. This is not possible and you can not show a dynamic date as default in the report using @prompt or by any other means..
Please go through the full blog by Dave blog specifically where it mentioned about default..
Hi Veena,
In the above sysntax, could you try replacing "7 days" with an object calculating the defautl date you require or with Sysdate() function if you using ORacle as DB?
Also, I tried creating a date prompt at the WebI (version 3.1) level with Default Date as 01/01/2013, and every time the report is refreshed, default date is present..no user selection is required.
Am i interpreting your requirement wrongly?
what version of BO you Using?
You want the prompt to be at Universe Level or Report Level?
Sujit
Can you update with your @prompt code which works for default date?
Durga, i have done this at the Report Level, Webi Prompt window provides you with an option to set the default values.
Let me check the SQL syntax generated, will update you.
Sujit
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Set Default in the Prompt function which will always displays that date
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
alternatively, prompts are the report level provide you with option to select default values,, you can try that if not already selected.
It also provides you to refer to variabe, You can create a variable to calculate the required date and reference it in this prompt.
try it,
Sujit
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You can create a date object with the required date, and then use this object in the @Prompt function as a parameter for "default values"
Let me know if this helps,
Sujit
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
If you are looking for a default date like today or a relative date like first day of last month ; I will suggest to look into the link below where Dave has explained the process brilliantly
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.