cancel
Showing results for 
Search instead for 
Did you mean: 

Displaying 00/00/0000 in the report

sudhir_vanap
Explorer
0 Kudos
678

Hello All,

We have a report in BW system where in it shows the Freight rates, changed date and user who has done it.

and it is fetching the date Information directly from CDPOS table in SAP where there are few Invalid entries like '0146/1/' and '147/01 '

So business has requested to make this Invalid date entries as to be appeared as 00/00/0000 in the report output.

We have written sample code in BW side to make all Invalid date as 00/00/0000, but when the load from Inbound DSO to cube happens,

the data in the cube is appearing as blank value and in the report it is appearing as '#'.

Could any body please help me here as I need to display that value 00/00/0000 as it is in the report output.

Accepted Solutions (0)

Answers (3)

Answers (3)

anshu_lilhori
Active Contributor
0 Kudos

You need to store that date as keyfigure.Make keyfigure of type date and map with the characteristic date.

If you store it is characteristic then for blank records it will show as # but for keyfigure you will get your desired format.

Regards,

AL

sudhir_vanap
Explorer
0 Kudos

Is there any way...in Query level can we convert this date char to Key figure, as this is only for display purpose......?

anshu_lilhori
Active Contributor
0 Kudos

Yes you can convert the char into keyfigure with the help of replacement path and then it should show you the date as desired when blank.

Give it a try.

Regards,

AL

Loed
Active Contributor
0 Kudos

Hi Sudhir,

Check this doc for converting your DATE to keyfigure:

In the CURRENCY/UNIT tab, just choose DATE..

Regards,

Loed

former_member186053
Active Contributor
0 Kudos

Hi Sudhir,

What is the data types of your date fields. Debug the code and see how the values are updating into those fields.

Regards,

Vengal.

Former Member
0 Kudos


Hi,

Can you put down the code written to achieve this.

Regards,

Anupama

sudhir_vanap
Explorer
0 Kudos

It is small code snippet that has been written from Inbound to staging...

as we know the existing Invalid entries in CDPOS..we have written like this

DATA : LV_DATAB TYPE /BIC/OIZOLDVLFRM.

       LV_DATAB = SOURCE_FIELDS-OLD_DATAB.
     If LV_DATAB = '0147/1/ ' OR LV_DATAB = '0141/1/ ' OR LV_DATAB =
     ' ' OR LV_DATAB = '0146/1/ ' OR LV_DATAB = '0148/1/ ' OR LV_DATAB =
     '45/19'.
       LV_DATAB = '00/00/0000'.
     Else.
    RESULT = LV_DATAB.
    ENDIF.

and also the data type is the same, it is the  DATE field

former_member186053
Active Contributor
0 Kudos

Hi Sudhir,

Can you try to define the LV_DATAB as NUMC or STRING type and see you can able to get it.

Regards,

Vengal.