SAP Knowledge Base Article - Public

3278586 - How to cast type DECFLOAT34 to type CURR

Symptom

How to cast type DECFLOAT34 to type CURR in calculation when building a Custom CDS view?

Environment

SAP S/4HANA Cloud 

Resolution

Cast via casting the decfloat to first in decimal format and then to a currency.

Sample statement:

cast ( cast ( YY1_Sample as ABAP.DEC( xx, x ) ) as ABAP.CURR( xx, x ) )

Keywords

DECFLOAT34, CURR, calculation, cast , KBA , BC-SRV-APS-GKE , Generic CDS Key User Editor , How To

Product

SAP S/4HANA Cloud all versions