This website is not affiliated with, sponsored by, or approved by SAP AG.

SAP BEx Query Designer

Business Warehouse

Moderators: Snowy, thx4allthefish

SAP BEx Query Designer

Postby mackixv » Wed Mar 21, 2012 2:58 am

having problems with using data function: process value as date

a = 1000

formula: date(xdate)<date(062011) * (a*1.2) + date(xdate) >= date(062011) * (a*.1.5)

date selection: 05.2011-06.2011

xDate ............38195.....75304

should be:
xDate............052011..... 062011

please help on how to convert to date and the correct "if" formula

thanks in advance
macki_xv ^_^
Posts: 1
Joined: Wed Mar 21, 2012 2:38 am

Re: SAP BEx Query Designer

Postby JohnLang » Thu Mar 22, 2012 5:17 am

Hi mackixv,

You will need to change your variables to be true dates at the day granularity if you want to use the date() formula.
Use of any month variables or values (Like 062012) will not work with the date() formula.

The query designer formula for date() uses integer numbers in the internal format of YYYYMMDD. SAP has a programming native data type that uses a date in this format but not in your normal base 10 integer number line; it specifically allows for addition and subtraction of integer values that are treated as days and the actual calculation accommodates for the real calendar days so that it emulates basic arithmetic but uses "Base Calendar Day" (for want of a better description).

For example: 20111231 + 1 = 20120101
For example: 20120301 - 1 = 20120229

Kind Regards,
Posts: 16
Joined: Wed Jul 20, 2011 3:56 am
Location: Australia

Return to Business Warehouse

Who is online

Users browsing this forum: No registered users and 3 guests


This website is not affiliated with, sponsored by, or approved by SAP AG.