Expand my Community achievements bar.

Adobe Summit 2025: AEP & RTCDP Session Recordings Are Live! Missed a session or want to revisit your favorites? Watch the latest recordings now.
SOLVED

Query Regarding multiple schemas for AEP and Adobe Analytics

Avatar

Level 2

Hi there,

 

I have configured a schema using Adobe Analytics Experience Event Field Group (Schema 1)

I have another schema with a set of Custom Fields (Schema 2)

Primary reason for using AA Experience Event Field group is to send data to AA through Launch Web SDK. I do not want all fields on Schema 1 to be passed into AEP. Hence, schema 2 is created with only required fields to be sent to AEP.

 

I have Adobe Launch implementation to send data to edge network on various interactions (page view, page scroll, link click, product view etc.) . However, I want to send data to AEP only on page view event.

Using data object (data.__adobe{}) is one of the method of achieving this.

But, Is there any other way to achieve this using Data Prep mapping with Schema 1 and Schema 2? 

If I use data prep to map the fields, say xdm._experience.analytics.customDimensions.eVars.eVar1 (Schema 1)  ---> schema2.pageName (Schema 2), it will map and send data on all interactions rather than just page views.

 

Thanks in advance  

 

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

Hi @AbhilashSharmaN ,

I'd recommend using data.__adobe{} for AA payload on all interactions and add xdm{} for AEP payload on page views events. This will eliminate the need of maintaining two schemas as you'll only need to create schema for the AEP xdm{} payloads.

Incase you want to achieve this through xdm{} payloads only, you should explore DataStream Override option in data AEP SDK's sendEvent() method.

Here's how it'll work for your use case of sending only page views to AEP,

  • Create two schemas,
    • Schema 1: configure using Adobe Analytics Experience Event Field Group only
    • Schema 2: configure using Custom Fields only
  • Create AEP Dataset 2 only for Schema 2
  • Create two DataStream,
    • DataStream 1:
      • Configure it with Schema 1
      • Add only AA service and don't add AEP service
    • DataStream 2:
      • Configure it with Schema 2
      • Add both AEP service and AA service
      • Add data prep mapping from AA fields to AEP fields like xdm._experience.analytics.customDimensions.eVars.eVar1  ---> xdm._tenantID.pageName
  • In data collection use DataStream 1 as default DataStream for AEP SDK configuration
  • Use AEP SDK sendEvent() method to track all interactions except page view events with AA formatted xdm{} payloads (This sends data to AA using DataStream 1) 
  • On page view event's sendEvent() action pass AA formatted xdm{} payload and use the datastream override option to select DataStream 2 and AEP Dataset 2,
  • Harveer_SinghGi1_0-1738561625843.png
  • In above action both AA and AEP xdm{} fields (AEP fields will be populated through data prep mappings) will be sent to AA and AEP both the tools will keep their respective fields and discard remaining ones.

Cheers!

 

View solution in original post

5 Replies

Avatar

Correct answer by
Community Advisor

Hi @AbhilashSharmaN ,

I'd recommend using data.__adobe{} for AA payload on all interactions and add xdm{} for AEP payload on page views events. This will eliminate the need of maintaining two schemas as you'll only need to create schema for the AEP xdm{} payloads.

Incase you want to achieve this through xdm{} payloads only, you should explore DataStream Override option in data AEP SDK's sendEvent() method.

Here's how it'll work for your use case of sending only page views to AEP,

  • Create two schemas,
    • Schema 1: configure using Adobe Analytics Experience Event Field Group only
    • Schema 2: configure using Custom Fields only
  • Create AEP Dataset 2 only for Schema 2
  • Create two DataStream,
    • DataStream 1:
      • Configure it with Schema 1
      • Add only AA service and don't add AEP service
    • DataStream 2:
      • Configure it with Schema 2
      • Add both AEP service and AA service
      • Add data prep mapping from AA fields to AEP fields like xdm._experience.analytics.customDimensions.eVars.eVar1  ---> xdm._tenantID.pageName
  • In data collection use DataStream 1 as default DataStream for AEP SDK configuration
  • Use AEP SDK sendEvent() method to track all interactions except page view events with AA formatted xdm{} payloads (This sends data to AA using DataStream 1) 
  • On page view event's sendEvent() action pass AA formatted xdm{} payload and use the datastream override option to select DataStream 2 and AEP Dataset 2,
  • Harveer_SinghGi1_0-1738561625843.png
  • In above action both AA and AEP xdm{} fields (AEP fields will be populated through data prep mappings) will be sent to AA and AEP both the tools will keep their respective fields and discard remaining ones.

Cheers!

 

@Harveer_SinghGi1 , Thank you so much for the detailed explanation!! Its crystal clear for me now.

I will give this a shot.

 

Cheers,

Abhi.

Hi @Harveer_SinghGi1 , 

I tried the solution you suggested and it worked as per the expectation! Thanks so much for your inputs

 

I have an additional question. Let's say I use data__adobe:{} method for sending data to AA and have a separate custom schema for AEP needs. 

I have a schema field "ECID" where I need to pass the experience cloud ID only on page load event.

Adobe recommends using Data Prep in DataStream to map "xdm.identityMap.ECID[0].id" to "xdm._tenantID.ECID" .

 

I use ACDL in my implementation. Accessing ECID on the client side using the below code sometimes doesn't set ECID before the page load rule executes (Due to timing issue). So Data Prep is my only option.

return alloy("getIdentity")
.then(function(result) {
_satellite.setVar("ECID", result.identity.ECID);
});

 

If I set the data prep, will it not send ECID info on all server call that happens (page load, link clicks, product views etc.) ?

In this case, do I need to have a separate DataStream for page views and use Data Stream override for page load event?

 

Looking forward for your response on this.

 

Cheers,

Abhi.

Avatar

Community Advisor

HI @AbhilashSharmaN ,

First of all please note that mapping xdm._tenantID.ECID field through data prep won't make ECID information available in data__adobe:{} object, you'll have to read xdm._tenantID.ECID field through AA processing rules (where it will show up a context variable named a.x._tenantID.ECID) and map it to desired AA variable.

Now for mapping the ECID to the custom XDM field, you don't need a separate DataStream for this requirement, this can be achieved through a calculated field in data prep.

In your XDM you should have either one or both of these fields populated for page view events,

  • xdm.web.webPageDetails.pageViews.value = 1
  • xdm.eventType = "web.webpagedetails.pageViews"

Using these fields you can create a calculated source field to populate ECID only on page view events like below and then map this source field to xdm._tenantID.ECID target field,

iif(xdm.eventType == "web.webpagedetails.pageViews" || xdm.web.webPageDetails.pageViews.value == 1,xdm.identityMap.ECID[0].id,nullify())

This conditional calculated field will populate the custom XDM field only on page views and not on any other call.

Cheers! 

Avatar

Level 2

Thank you @Harveer_SinghGi1 for the detailed answer!! I am clear now.

Cheers,

Abhi.