ERPNext.com Frappe Cloud Support Partners Foundation Frappe School

How to add a description field from a linked doctype

Hello Everyone
When we add a link field to a doctype, the link field will store the name of the linked record.
We would like to add an extra filed to the doctype to show like a description of the linked record, without storing anything in the doctype.
Let say, we have:
Doctype: Product Category has the following data:
name, code, description
EL, EL, Electronics
SF, SF, Software

Doctype: Product has a link to Product Category. The link stores the code of the category only. And we need to show in the Product doctype the description of the category as well, but without storing it in the Product table. So if the description of the category changes, it will get reflected in the Product doctype.

Kindly advise
Aissa