Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

The 4th edition of the Campaign Community Lens newsletter is out now!

Add delivery property to delivery log

Avatar

Level 2

Hi,

We have added a custom field to a delivery template.

I would like to use the field for calculating a date, and then save it in a custom field in the delivery log upon delivery execution.

Can this be done without making a post-processing workflow? What is the best way to do this?

7 Replies

Avatar

Level 7

Hi @_lukas_ ,

 

You can save the additional fields from nms:Delivery to nms:broadLogRcp using Target Mapping too.

Here is the link to a similar query where I'd suggested the steps as to use Target Mapping,

https://experienceleaguecommunities.adobe.com/t5/adobe-campaign-classic-questions/how-can-i-log-the-... 

 

Let me know if you have any futher questions while achieving this. 🙂

 

Br,

Shubham

Avatar

Level 2

Thanks for such fast reply.

Do I add this in the nms:recipient target mapping? Or do I need a nms:delivery mapping for this?

Because when trying your suggestion on the nms:recipient mapping, I am stuck on how to reference fields in the delivery-table.

Avatar

Level 7

Hi @_lukas_ ,

 

Yes, the fields you like to pass to your nms:broadLogRcp needs to be added to "nms:recipient" (mapRecipient) Target mapping.

In mapRecipients you need to add the fields (under: Soruce Expression) e.g. [targetData/@feildName] that will be passed from the targeting schema like nms:delivery and then map them to the actual fields (under: Destination) that you have extended in broadLogsRcp table to store this additional data e.g. (@feilds).

Also, you can include information permanently from other tables like the Recipient table by using [recpient/@email].

 

Below screenshot might help you to understand this better. 🙂

 

In the below screenshot the values of emailType, emailSubject is picked from the targeting workflow that is used to send the delivery, and when delivery is processed these data get automatically stored to the destination path of nms:broadLogRcp

 

_Shubham_Goyal__0-1674128370157.png

 

Br,

Shubham

Avatar

Level 2

Thanks again for the explanation,

Next question, how do I add this information to targetData without adding it in the WF query activity as "Add data"?

 

I would like to be able to do this in the delivery activity it self so I can just make this adjustment to the delivery template, otherwise I would need to update all WF's with add data. I have been looking into the "extra script object" in the personalization tab but I don't understand how to use it or if it is possible to use it for this use case.

Avatar

Level 7

Sure, I'll help! 🙂

 

But can you share more information on the custom fields that you have added to the delivery template that you like to export to broadLogs too?

Also, could you explain how will be using it to calculate the date, as you mentioned above? and where you will be storing this final calculated date coz this final cal date seems to be the value/field that you like to store in broadLogs? 

 

Br,

Shubham

Avatar

Level 2

Thanks! 🙂
It is a dynamic date calculation which is based on an input field in the delivery input form. It is stored in daysToAddToCurrentDate in the nms:delivery-schema, by using an extension schema.

 

So when executing the delivery I would like to set a column in the broadLogRcp-table to AddDays(GetDate() + [delivery/@daysToAddToCurrentDate])

 

Avatar

Level 7

Hi @_lukas_ ,

 

Though I haven't tested it myself yet, but I'm uncertain that using Object (extra field objects) we can store this calculated information to deliveryLogs via the process of Target Mapping>Storage.

As the ExtraObject will generate an object in the respective delivery which can then be used further in content personalization so you can use this object to calculate the date and display it in the content message to a recipient but I'm afraid if this object field can be further used as a 'Source Expression' in the 'Storage' tab of Target mapping for the deliveryLogs.

Though you can give it a try on your side and see if that help. 🙂

 

That said, I tried sometime more to think of an alternative solution for you, where you do need not to use the 'Add data' in each workflow to add this calculated field column but sorry couldn't find any. 😕 Now, the reason for that is if you using the mapRecipient - Targeting mapping way to store information to nms:broadLogRcp then that data/info should be linked to recipients so you either can pick that info directly from the nms:recipient table or else via targetData that comes from targeting workflows.

Therefore, in my opinion, to achieve your requirement you might need to use 'Additional data' to calculate your date and then map it in the target mapping as suggested above.

 

P.S. you can also wait and see if any other community folks have any better suggestions to achieve this than mine. 🙂

 

Br,

Shubham