I have TriggerSend that I call using the web api.
in the Email there is AMPScript
A section of that AMPScript is suppose to clear data from named Data Extensions. However, no rows are ever removed.
here is the code:
if Not Empty(@order_id) then
DeleteDE("order", "order_id", @order_id)
DeleteDE("order_product", "order_id", @order_id)
DeleteDE("order_shipping", "order_id", @order_id)
endif
A few things.
I know for a fact that @order_id has a value, because in the body of the email, I echo out the value
Your Order id is #%%=v(@order_id)=%%
which correctly displays the order value.
However, even though the email is sent, and the order value in the email body is correct, and points to rows in the DE that contain that order id, they are not deleted.
Can someone please help me with this issue?