Hi All,
First scenario is-
I have two entities contact, and population in CDS. I want to create relationship between these two. How can I relate them so that I get below highlighted columns in respective entities?
Currently in contact entity we do not have contacts created yet but in population entity we have all the users basic record like name, emp id, email id, company name etc. When the user register on the portal ,the particular record gets inserted in contact and accordingly, we want to map that user with population entity.
For instance -

Second scenario is-
I have three entities contact, work and population in CDS. Suppose a user 'X' is logged in on portal. I have created one form using work entity fields. When the user fill the form and submit it, the entry will be recorded in work entity. Now, I want to fetch lookup value from work and population in work entities (i.e. contactlookup and populationlookup) for user X.
For instance- When User X logged in I want contactlookup and populationlookup columns to be 3 and 1 based on data as shown in fig.
Currently, When I logged in as User X the entry gets recorded in work entity but the columns-contattlookup and populationlookup does not contain any data.
How can I achieve that?
Any help is appreciated.
Thank You in advance.