cancel
Showing results for 
Search instead for 
Did you mean: 

Prompt to display dates

Former Member
0 Kudos

Hi ,

I would like a prompt which display dates to have default values.

The End Date is the current date and Begin Date is the fifth day from current date.

I created 2 objects (CURDAY and PRIOR 5 DAY) which represents these variables in Designer and use them in the extended prompt syntax.

The syntax applied is:

@Select(Calendar \Data Rif) BETWEEN @Prompt('Enter Begin Date','DATE','Calendar \Date Rif,MONO,FREE,NON-PERSISTENT, ,) AND @Prompt('Enter End Date', 'DATE', 'Calendar \Date Rif,MONO,FREE,NON-PERSISTENT, {PRIOR 5 DAY},)

CURDAY is an object in designer which returns the date of the current day whereas PRIOR 5 DAY returns the date of the fifth day from current date.

Unfortunately, it doesn't function. The prompt still ask for dates.

Where I am wrong or is there any other workaround I can use

Thanks in advance

krish

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Krish,

You cannot have dynamic default value in the prompt. You can only have the static text as a default value and at the back-end

you have to handle it vai case statement or decode statement.

You have to use the following work-around for that.

@Select(Calendar \Data Rif) In

Case @Prompt('Enter Begin Date','DATE','Calendar \Date Rif',mono,free,Not_Persistent,{'CURDAY'},)

When CURDAY

Then Select Sysdate from Dual

Else @Prompt('Enter Begin Date','DATE','Calendar \Date Rif',mono,free,Not_Persistent,{'CURDAY'},)

End

Similarly you to define for the other date.

Regards,

Rohit