I want create bi-direction relation between related list

Mayu
Tera Guru
Tera Guru

I have created custom related list on issue form .For that created m2m table  used planned task and issue table.

In issue form related list if i add one record it added to related list and if i open related list record so in that record need to show related record.

Mayu_0-1741181274803.png

In  above screenshot I have added 'Employee Management' added to ' 

 
 

 

 

7 REPLIES 7

Ankur Bawiskar
Tera Patron
Tera Patron

@Mayu 

you can create defined relationship as this

Applies to Table - Issues

Queries from table - sn_grc_issue

Script:

current.addQuery('plannedTaskField', parent.sys_id);

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
✨ Certified Technical Architect  ||  ✨ 9x ServiceNow MVP  ||  ✨ ServiceNow Community Leader

@Ankur Bawiskar  I have created relationship 

Mayu_0-1741188201235.png

 

still it is not showing directional relation.could you please suggest me.

eg IPT0020004 in related list  i added  issue IPT0020013 record when i open IPT0020013 in that issue related list should be show IPT0020004 record.

 

Thank you

 

@Mayu 

Logic I already shared, please ensure you use the correct field i.e. u_planned_task

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
✨ Certified Technical Architect  ||  ✨ 9x ServiceNow MVP  ||  ✨ ServiceNow Community Leader

@Ankur Bawiskar  Thank you for your help I have only one doubt is this best practice to make this bi-direction relation? I have checked all community doc but nothing found related to best practice related things

Thank You.