cancel
Showing results for 
Search instead for 
Did you mean: 

Key Date value as parameter in crystal report

dexr_soepriyadi
Explorer
0 Kudos

Hi All,

I have 2 problems:

1st problem:

We try to use crystal report to pass key date to SAP BW queries. I have a variable on SAP BW queries on key date. The variable is 0P_DATE_OPEN

Instead of date yyyymmdd (e.g. 20110615), i have to enter value as follow: [0NETDUEDATE].[20110615].

Above is 1st problem

2nd problem, i cannot change the parameter from String to Date in order to leverage the "nice date button" on the Crystal report standard date parameters.

Appreciate any help and many thanks !

Cheers,

DEX

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Can you have the parameter as Date, but then do the following?

Eg: parameter name = {?Date}

Create a formula with name eg: fmtDate with the following:

'0NETDUEDATE'&Totext({?Date},"yyyyMMdd")

In you record Selection, you have something like

0P_DATE_OPEN=@fmtDate

Something along that line. Hope it helps.

dexr_soepriyadi
Explorer
0 Kudos

I tried to assign 0P_DATEOPEN = [NETDUEDATE].[201106015] in record selection but it turn removes all the data.

fyi: 0P_DATE_OPEN is a mandatory SAP BW Variable.

So what i want to ask is, can crystal report assign default value to SAP BW mandatory variable ? before MDX is being sent to SAP BW.