Expand my Community achievements bar.

SOLVED

Primary Key defined in Schema's using autopk and key field attribute

Avatar

Employee

Hello Team,

Difference between autopk="true" defined for primary and primary key defined via <key><keyfield> attribute. Please let me know the difference between the two?

Best Regards,

Nidhi

1 Accepted Solution

Avatar

Correct answer by
Employee

Hi Nidhi,

Autopk="true" is used to declare a unique key.  Read below -

  • autopk (boolean): if this option is activated (autopk="true"), a unique key will be automatically defined. This option may only be used on the main element of the schema. Warning, Adobe Campaign only guarantees that the key generated is unique. It is not guaranteed that the key values are consecutive and incremental.

Thanks

Deepak

View solution in original post

1 Reply

Avatar

Correct answer by
Employee

Hi Nidhi,

Autopk="true" is used to declare a unique key.  Read below -

  • autopk (boolean): if this option is activated (autopk="true"), a unique key will be automatically defined. This option may only be used on the main element of the schema. Warning, Adobe Campaign only guarantees that the key generated is unique. It is not guaranteed that the key values are consecutive and incremental.

Thanks

Deepak