BookmarkSubscribeRSS Feed
Asmaaa
Calcite | Level 5

I have create a campaign In SAS MA, and I want to export a list of informations about the client (Id client, Name Client, Last Name Client, Age, Work category, Sex Client, Message),

 

I want the variable Message to be a calculated Item that return a message like : 

 

Case when  work category = Worker and sex_client = M then " Dear Mr <<Name of the client>> ........" somthing like that 

is it possible in SAS MA ? 

 

Thank you

3 REPLIES 3
Dmitry_Alergant
Pyrite | Level 9

Hi Asmaaa, certainly you can do that by creating a Calculated Item called "Message". There is plenty of information of how to create calculated items in SAS MA User Guide.

 

In your case, your calculated item formula will be based on case statement (case when ... then ... when ... then ... else ... end);

 

Something like 

case

when <<category>> = "Worker" and <<sex_client>> = "M" then  "Dear Mr. " || <<Name of the client>> || ", good bye!"

when <<category>> = "Student" and <<sex_client>> = "F" then  "Sorry we don't deal with female students, come back later, bye!"

else "Hey we don't know you, bye"

end

 

Hope it helps!

-------
Dmitriy Alergant, Tier One Analytics
zuzak
Calcite | Level 5

case when <</Client/TOP items/Customer Context>> = 'CZ' then

case when <</Client/Imported Data/Dummy Char3>>='na pobočku.'
then
'text1'
else case when <</Client/Imported Data/Dummy Char3>>='address'
then
'text2'
else case when <</Client/Imported Data/Dummy Char3>>='na kontaktní adresu.'
then
' ve virtuální podobě do mobilní aplikace Smart Banking. V případě že budete potřebovat plastovou kartu, můžete si o ní jednoduše požádat kdykoliv zdarma v aplikaci.'
end end end

case when <</Client/TOP items/Customer Context>> = 'SR' then

case when <</Client/Imported Data/Dummy Char3>>='na pobočkuSR.'
then
'text1'
else case when <</Client/Imported Data/Dummy Char3>>='addressSR'
then
'text2'
else case when <</Client/Imported Data/Dummy Char3>>='na kontaktní adresu.'
then
' ve virtuální podobě do mobilní aplikace Smart BankingSR.'
end end end

zuzak
Calcite | Level 5
-validni
case when <</Client/TOP items/Customer Context>> = 'CZ' then

case when <</Client/Imported Data/Dummy Char3>>='na pobočku.'
then
'text1'
else case when <</Client/Imported Data/Dummy Char3>>='address'
then
'text2'
else case when <</Client/Imported Data/Dummy Char3>>='na kontaktní adresu.'
then
' ve virtuální podobě do mobilní aplikace Smart Banking. V případě že budete potřebovat plastovou kartu, můžete si o ní jednoduše požádat kdykoliv zdarma v aplikaci.'
end end end
How to improve email deliverability

SAS' Peter Ansbacher shows you how to use the dashboard in SAS Customer Intelligence 360 for better results.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 3 replies
  • 1620 views
  • 0 likes
  • 3 in conversation