The Zurich release has arrived! Interested in new features and functionalities? Click here for more

Create Parent/Child Related Table

kanielb1
Mega Expert

I was having issues creating a related list from a child table that extends a parent table.   I found this article and created the Parent column on the child table as a reference to the parent table.   It was then showing as a Related List.   When I added the related list, it was showing Parent = (empty).   The parent field is also not populated on the form?   What am I missing?

Parent.PNGparent2.PNG

1 ACCEPTED SOLUTION

kanielb1
Mega Expert

I had another reference column on the table with the display value set to true.   I made that false and the parent was populated.


View solution in original post

5 REPLIES 5

Goran WitchDoc
ServiceNow Employee
ServiceNow Employee

Think you got the wrong parent related list. You also need to manually set the parent on the child form? And after reading your text, it doesn't seems you have created the relationship either(which is mention in the article) you link to.



//Göran


Can you elaborate on how to manually set the parent on the child form?  



I created a relationship in System Definition>Relationships.   This did not resolve anything.


current.addQuery('parent', 'parent.number');


Kaniel



  After adding a reference field on the Child table which references to Parent table, go to the Parent table form and right click on the header and select Configure then you will see a Related Lists option. When you click on the Related Lists, you will see your newly created relationship in the available list in this format


<Child Table Name> --> <Newly created field on the child table>. Just add it to the Selected List



For example, If I create a reference field "Test" on the Incident table referencing Change Request table, then when you go to the Related lists on the Change Request table, you will see a List with the name "Incident-->Test"



Thanks,


Abhinay


kanielb1
Mega Expert

I had another reference column on the table with the display value set to true.   I made that false and the parent was populated.