Expand my Community achievements bar.

Create Composite Primary Key for XDM Individual Profile Schema

Avatar

Level 2

We got a use case where we want to have composite primary key or a unique value for a combination fields of schema. We tried to add unique index using query service but failed to achieve. It will be very helpful if anyone assist me how to achieve.

Thanks in advance.

1 Reply

Avatar

Level 5

You might be unable to add a unique index using the query service because one possibility is that the fields you try to index are not unique. Another possibility is that the index you are trying to create is already present.

If you are not sure why you are not able to add a unique index, you can try the following:

  • Check the fields you are trying to index to ensure they are unique.
  • Check the already present indexes to see if they include the fields you are trying to index.
  • You can contact Adobe Experience Platform support for assistance if you are still having trouble.

If you are planning to create a unique index, you should carefully consider the following:

  • The fields you want to index
  • The queries you will be running
  • The uniqueness constraints you need to enforce

By carefully considering these factors, you can create unique indexes that will improve the performance of your queries and enforce your data integrity constraints.