Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
hi i have the following if statement that is not working.
i recieve the first two codes and no dates, however there should be a joined key.
ie . SEK20140101 , instead i recieve SEK or EUR only without the date, i guess i have a brackets issue.
Best Bras
If("TO_SHOP_NO" <= 299,'SEK',
If(("TO_SHOP_NO" >= 400 and "TO_SHOP_NO" <= 499) or ("TO_SHOP_NO" >= 610 and "TO_SHOP_NO" <= 699),'EUR',
If("TO_SHOP_NO" >= 600 and "TO_SHOP_NO" <= 609,'EEK'
& Date(MakeWeekDate(Left(TO_PERIOD,4),Right(TO_PERIOD,2),0),'YYYYMMDD'))))
Try:
If("TO_SHOP_NO" <= 299,'SEK',
If(("TO_SHOP_NO" >= 400 and "TO_SHOP_NO" <= 499) or ("TO_SHOP_NO" >= 610 and "TO_SHOP_NO" <= 699),'EUR',
If("TO_SHOP_NO" >= 600 and "TO_SHOP_NO" <= 609,'EEK')))
& Date(MakeWeekDate(Left(TO_PERIOD,4),Right(TO_PERIOD,2),0),'YYYYMMDD')
Hope this helps!
Try:
If("TO_SHOP_NO" <= 299,'SEK',
If(("TO_SHOP_NO" >= 400 and "TO_SHOP_NO" <= 499) or ("TO_SHOP_NO" >= 610 and "TO_SHOP_NO" <= 699),'EUR',
If("TO_SHOP_NO" >= 600 and "TO_SHOP_NO" <= 609,'EEK')))
& Date(MakeWeekDate(Left(TO_PERIOD,4),Right(TO_PERIOD,2),0),'YYYYMMDD')
Hope this helps!
Hi Brad,
Question: What about values that fall out of those specific ranges?
--john
I assume that expression-matching isn't the only one from this kind in your apps and you will need it so or with slight changes quite often. Then it's better to create a extra field for this as matching-table or joined to the TO_SHOP_NO - you will need only one or two minutes in excel to create such a table.
- Marcus
you are right Marcus!
thank you for the great advice.
Hi John!
good question.
i am only looking at matching those specific values, the outliers are categorized as other sales channels , however for this purpose we are focused on the store channel.
Best
Brad