Expand my Community achievements bar.

SOLVED

To update an existing Event record in AEP

Avatar

Level 1

Hi all,

 

I would like to update an event record within an Experience Event dataset. While I am aware that event records cannot typically be updated, the Adobe team has provided the following guidance:

" Yes, RTCDP does support append or upsert operations to ExperienceEvent data using _id or a unique identifier.

 

In case of dataset:
- Enable dataset for real time customer profile
- add the tag "isUpsert": true

 

In case of schema, make sure to:
- It is based on the XDM ExperienceEvent class
- _id is unique to identify events
- Schema is Profile-enabled

 

Some helpful links:
1) https://experienceleague.adobe.com/en/docs/experience-platform/catalog/datasets/enable-upsert
2) https://experienceleague.adobe.com/en/docs/experience-platform/data-prep/upserts
3) https://experienceleaguecommunities.adobe.com/t5/adobe-experience-platform/how-to-use-data-prep-fun…
"
I tried following the similar steps, but I am not able to update the event record.
Can someone please guide me on how to proceed?

Topics

Topics help categorize Community content and increase your ability to discover relevant content.

1 Accepted Solution

Avatar

Correct answer by
Employee

As @Tof_Jossic has noted an XDM Experience Event Class schema will track an event at a point in time.  The _id in an experience event should be used to uniquely identity the event which has occurred for the identity in the payload.  

 

Upsert is support for an XDM Experience Profile Class.  By default an XDM Experience Profile Class schema will capture the data elements which were last ingested into the schema.  Upsert allows for the write of data, but not all data elements in the dataset are required.  Please see the example below.

 

1) Initial write of data upon a XDM Experience Profile class dataset

data write > id: 12345, status: gold, tier: ultimate, Name:Jon Smith

 

2) Upsert write of data upon XDM Experience Profile class dataset

data write > id: 12345, status: bronze

 

Resulting record:

id: 12345, status: bronze, tier: ultimate, Name:Jon Smith

View solution in original post

6 Replies

Avatar

Level 1

@kautuk_sahni @Harveer_SinghGi @DavidRoss91 Can you please help me with this?

Avatar

Employee Advisor

@BahadurAh from experience, while you can send additional ExperienceEvents (each with its own _id), that’s just normal event ingestion, not an “append to an existing event”.

As for ExperienceEvents Upsert, this is not supported. _id is used for identity and deduplication (because duplicates with the same _id will be dropped in Profile), not for in-place updates. ExperienceEvents are immutable.

Avatar

Level 2

Hi @brekrut  @Tof_Jossic ,

We have a use case to flag bot activity on events. Instead of re-ingesting the bot-flagged events, we would like to update or flag the existing events. We raised an Adobe ticket some time back, and we were informed that this should be possible.

We tried the following approaches:

  1. Enabled upsert on the event dataset, but it resulted in an error.

  2. Re-ingested the same event with updated information; however, since the '_id' was duplicated, the event was rejected and did not appear in AEP.

If updating existing event data is not supported, is there a way to update an enum or add a flag to mark the event as bot activity?

Avatar

Employee

Upsert is intended to be used by an XDM Experience Profile class.  

 

It appear you are attempting to replay an event but flag it as an bot.  Using query service to identity a bot event is an option, but ideally identity the bot behavior at the source would be ideal.  

See the following for enabling bot detection and scoring:

https://experienceleague.adobe.com/en/docs/experience-platform/datastreams/bot-detection#

Avatar

Level 2

Hi @brekrut,

Thank you for sharing the link. I had a chance to review it, and it looks like it may not fully address our use cases below:

Identifying bot activity in already ingested data in AEP – While we are able to identify such events using Query Service, our intent was to flag the existing events rather than re-ingesting them into a new dataset.

Bot activity detection for tracklog and open/click data – The rules we are evaluating are mainly based on rapid clicks and engagement timing.

We have been exploring ways to enable upsert for events; however, based on your explanation, we understand that this may not be feasible. Could you please advise if there is any recommended approach to handle these scenarios?

Avatar

Correct answer by
Employee

As @Tof_Jossic has noted an XDM Experience Event Class schema will track an event at a point in time.  The _id in an experience event should be used to uniquely identity the event which has occurred for the identity in the payload.  

 

Upsert is support for an XDM Experience Profile Class.  By default an XDM Experience Profile Class schema will capture the data elements which were last ingested into the schema.  Upsert allows for the write of data, but not all data elements in the dataset are required.  Please see the example below.

 

1) Initial write of data upon a XDM Experience Profile class dataset

data write > id: 12345, status: gold, tier: ultimate, Name:Jon Smith

 

2) Upsert write of data upon XDM Experience Profile class dataset

data write > id: 12345, status: bronze

 

Resulting record:

id: 12345, status: bronze, tier: ultimate, Name:Jon Smith