How do I use apply this case expression when loading a .qvd?
Code works perfectly if my data source is SQL.
Looked at various examples posted on this forum, but could'nt find anything that deals with a date range?
when ImportDate between '2017-12-01 00:00:01' and '2017-12-31 23:59:00' then '2017/12' when ImportDate between '2018-01-01 00:00:01' and '2018-01-31 23:59:00' then '2018/01' when ImportDate between '2018-02-01 00:00:01' and '2018-02-28 23:59:00' then '2018/02' when ImportDate between ' 2018-03-01 00:00:01' and '2018-03-31 23:59:00' then '2018/03'' end as ConversionMonth
Hi how are you?? mmmmm it does not serve you directly to use the date to remove the year / month ?? try this: (Preceding Load) load *, year (ImportDate) & '/' & num (month (ImportDate), '00') as ConversionMonth;