Why are the data types of literals important?
Because otherwise the values must be converted into suitable types. This is usually done implicitly, but costs runtime. Where implicit conversion is not possible, errors occur.
SELECT DAYS_BETWEEN( CURRENT_DATE, '2000-01-01') FROM DUMMY
SELECT DAYS_BETWEEN( CURRENT_DATE, DATE'2000-01-01') FROM DUMMY
In BW transformations fields are e.g. emptied with ''
. But this sets the type of this column as a string. This leads to error messages with numeric key figures.
SELECT plant,
material,
'' as recordmode,
0 as amount,
...
FROM ...