Enrich pipeline policy using child record attributes


Is it possible to use enrich policy pipeline to perform a lookup against a child record to pull required attributes? I have 1 to 1 parent-child data in another index. But the attributes that I want to be included are only present in child records. How do I pull in such information?


As the match policy is based on a precise value, if the child document contains the parent id, that could be the lookup criteria?

Thanks. That is good option. But typically, the child will have parent id stored via routing. So if we need to use child record for lookup, then we will need to add the parent id as separate attribute into child record. But we will need to make sure that this attribute name does not conflict with parent record.

Currently, we have 1 to 1, parent child mapping. Child attribute updates are more frequent. But parent attribute updates have many variants. So we had separated out them into parent and child so that indexing can happen independently, irrespective of transaction type.

Now using enrich feature, I am trying to create a flatter index, where I am trying to populate both parent and child on parent record, irrespective of whether indexing is coming for parent record or child record. That will allow me to get rid of few complex has child queries. Will give this a shot. Thank you!

1 Like

@spinscale had 2 more questions. If I am getting an indexing action,

  1. is there a way to change the indexing action to upsert action? For example: lets say I am getting indexing to populate the child record. But i want to update the parent record with that information. Is that possible? Using set pipeline, you can change the index. But can we change the action?
  2. Using single indexing action, is it possible to update 2 indices or create 2 actions?
  1. Not that I am aware of, on top of my head. But, why not just doing a regular update action in that case?
  2. A single indexing action always only updates a single document

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.