on 02-07-2019 4:39 PM
Hello,
What is the precise reason of using @ObjectModel.representativeKey. I found few scn answers but found nothing that can explain the basics.
In CDS view as soon as I define any field as Foreign key, error to provide Representative key is prompted. If view from the association holds only one key (not composite) , is Representative key still required and why? How it affects the association.
Thank you so much.
Viren
Hi Viren,
As my understanding, representativeKey is the main column of a view, such as when you create a view containing columns like, controlling area, sales org, and sales org description, then sales org is the representativeKey, since this view is used to provide the text of sales org. When do the association, you may join this view with controlling area and sales org, system use representativeKey to see which field the text will be attached to. If the view only have one key, no need, since the text attached to the key auto.
Regards,
Franklin
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello SAP Team & Experts,
Kindly assist
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks Franklin. Yes after lots of tests I realised that.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
108 | |
12 | |
11 | |
6 | |
5 | |
4 | |
3 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.