Pressure rule whose WEIGHT depends on CURRENT DELIVERY FIELD | Community
Skip to main content
salvdangelo
Level 5
May 29, 2019
Solved

Pressure rule whose WEIGHT depends on CURRENT DELIVERY FIELD

  • May 29, 2019
  • 2 replies
  • 2659 views

Hello,

I'm trying to configure an advance pressure rule that is able to dynamically set the delivery weight

Weight formula is something like that:

Case(

When([emailInfo/delivery/@nature]='firstDelivery',6 ),

When([emailInfo/delivery/@nature]='secondDelivery',5),

When([emailInfo/delivery/@nature]='thirdDelivery',4),

When([emailInfo/delivery/@nature]='fourthDelivery',3),

Else(0) )

I used also [currentDelivery/@nature] but I anticipate that the results are the same.

The single delivery is configured in this way:

I realized that the pressure rule works only with a constant weight but doesn't fit expectation if weight depends on formula described adove.

Could you tell me if there is something wrong in my configuration?

Thanks in advance,
Salvatore

Jean-Serge Biron

Amy_Wong

Vapsy

florentlb

Amit Kumar

Adhiyan

Ananya Kuthiala

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by salvdangelo

Hello Jean-Serge Biron​ ,

I realized that it wasn't working because even if a recipient was included in more than 3 deliveries (6 in my test campaign):

  • Some of the deliveries remained on "Preparation" status and were not sent
  • The deliveries received were not those ones with the highest weight

In any case, it seems that I mis-configured the delivery: now I chose this weight type and it's working

Now, I would like to test the behavior on a 7 days period (previous 3,5 + next 3,5 days) and see what happens.
If you any suggestion or best action to apply, please feel free to reply here.

Thanks!
Salvatore

2 replies

Jean-Serge_Biro
Level 10
May 29, 2019

Hi Salvatore,

First of all, don't use emailInfo/delivery xpath, it takes the last delivery record sent to a recipient.

So you must use currentDelivery xpath for the delivery being analyzed.

How do you notice that the pressure rule doesn't behave as it should?
I guess you prepared and sent (or evaluated) 4 deliveries (because your quantity threshold is set to 3) with different nature values and same recipients targeted in same day (your period slice choice), and you checked which recipients were targeted depending on the nature value of deliveries?
Please elaborate how you deducted that the behavior is wrong?

Then please may you test with case/when/else syntax and [currentDelivery/@nature] but only on 2 levels of imbrication?

Or replace it by Iif syntax with 2 levels (with enclosed parenthesis for more levels)?
And also by changing the quantity to 1 so being able to test with 2 deliveries (easier for debugging).

Regards
J-Serge

salvdangelo
salvdangeloAuthorAccepted solution
Level 5
May 29, 2019

Hello Jean-Serge Biron​ ,

I realized that it wasn't working because even if a recipient was included in more than 3 deliveries (6 in my test campaign):

  • Some of the deliveries remained on "Preparation" status and were not sent
  • The deliveries received were not those ones with the highest weight

In any case, it seems that I mis-configured the delivery: now I chose this weight type and it's working

Now, I would like to test the behavior on a 7 days period (previous 3,5 + next 3,5 days) and see what happens.
If you any suggestion or best action to apply, please feel free to reply here.

Thanks!
Salvatore