I've a schema abc:multipleops (that stores all operations - transactions - related to a recipient) that I need to stablish a N-1 relationship with Recipients. The relationship should be visible from both sides.
documentation says, I just should not type: revCardinality
revCardinality (optional): with value “single” populates cardinality with type 1-1 (1-N by default)
So, this is what I need to enter to abc:multipleops, so multiple operations are linked to a single recipient???
I'm crossing revCardinality="single" meaning that I'll remove this part from the code below:
<element integrity="normal" label="Recipient" name="recipient" noDbIndex="true"revCardinality="single" revLabel="multipleops (Link)" revLink="multipleops"
revTarget="@codinterno" target="nms:recipient" type="link">
<join xpath-dst="@codinterno" xpath-src="@codinterno"/>
</element>
How can I validate it from the interface?
Solved! Go to Solution.
Views
Replies
Total Likes
In recipients you don't need to add anything when doing a N-1 to recipients.
Only in the table you want to modify.
Insert after last attribute:
<element integrity="normal" label="Recipient" name="recipient" noDbIndex="true"
revIntegrity="normal" revLabel="multipleops (Link)"
revLink="multipleops" target="nms:recipient" type="link">
<join xpath-dst="@codinterno" xpath-src="@CODINTERNO"/>
</element>
On the other hand, when it is a 1-1 Relationshipd, you need to modify both tables:
On abc:mytable
<element integrity="normal" label="Recipient" name="recipient" noDbIndex="true"
revCardinality="single" revIntegrity="normal" revLabel="mytable (Link)"
revLink="mytable" target="nms:recipient" type="link">
<join xpath-dst="@codinterno" xpath-src="@CODINTERNO"/>
</element>
on Recipients:
<element externalJoin="true" integrity="normal" label="mytable (Link)"
name="mytable" noDbIndex="true" revCardinality="single"
revIntegrity="normal" revLink="recipient" target="abc:mytable"
type="link">
<join xpath-dst="@CODINTERNO" xpath-src="@codinterno"/>
</element>
Views
Replies
Total Likes
Hi @god_prophet ,
In abc:multipleop schema, write the below script:
<element integrity="normal" label="Recipient" name="recipient" noDbIndex="true" revLabel="multipleops (Link)" revLink="multipleops" revTarget="@codinterno" target="nms:recipient" type="link">
<join xpath-dst="@codinterno" xpath-src="@codinterno"/>
</element>
Disconnect and reconnect the console.
Open abc:multipleop schemam> structure tab, you can see it is 1 to 1 link with Recipient table and Open Recipient schema > structure tab > display advanced field > you can see 1 to Many link (Orange color icon) created between recipient to multipleop
Views
Replies
Total Likes
Hi @god_prophet,
I see that you have another thread with the same content, where a solution has been provided. Can we close this thread based on the solution shared there: https://experienceleaguecommunities.adobe.com/t5/adobe-campaign-classic-questions/how-to-set-a-1-to-...?
Let us know. Thanks!
Views
Replies
Total Likes
Hi, those are differente... that one was about 1-1 relationship... this one is a 1-N relationship
Views
Replies
Total Likes
Oh yeah, sorry my bad. Thanks for clarifying though!
Views
Replies
Total Likes
In recipients you don't need to add anything when doing a N-1 to recipients.
Only in the table you want to modify.
Insert after last attribute:
<element integrity="normal" label="Recipient" name="recipient" noDbIndex="true"
revIntegrity="normal" revLabel="multipleops (Link)"
revLink="multipleops" target="nms:recipient" type="link">
<join xpath-dst="@codinterno" xpath-src="@CODINTERNO"/>
</element>
On the other hand, when it is a 1-1 Relationshipd, you need to modify both tables:
On abc:mytable
<element integrity="normal" label="Recipient" name="recipient" noDbIndex="true"
revCardinality="single" revIntegrity="normal" revLabel="mytable (Link)"
revLink="mytable" target="nms:recipient" type="link">
<join xpath-dst="@codinterno" xpath-src="@CODINTERNO"/>
</element>
on Recipients:
<element externalJoin="true" integrity="normal" label="mytable (Link)"
name="mytable" noDbIndex="true" revCardinality="single"
revIntegrity="normal" revLink="recipient" target="abc:mytable"
type="link">
<join xpath-dst="@CODINTERNO" xpath-src="@codinterno"/>
</element>
Views
Replies
Total Likes
Views
Likes
Replies
Views
Likes
Replies
Views
Likes
Replies
Views
Likes
Replies