function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
UmeShinUmeShin 

inline edit for the relational record in the lightning datatable

How can we make inline edit form features for relational record in the lightning datatable?
Below is the current code, and I would like to you to correct this code to achive inline edit for relational reocrd.
component

<lightning:datatable columns="{!v.columns}"
                             data="{!v.data}"
                             keyField="id"/>

Javascript
var columns = [
            {label:'product code', fieldName:'prod_code', type:'STRING', editable:true},
            {label:'product name', fieldName:'prod_name', type:'STRING'}, editable:true},
            {label:'employee name', fieldName:'emp_name', type:'url', editable:true, typeAttributes:{label:{fieldName: "emp_name"}}}
 ];
//please assume that employee name is the relational record with a parent object.
//and other two records are the normal records.
component.set("v.columns", columns);

 var data = [
            {prod_code:"001K89", prod_name:"product A", emp_name:{Name:"employee A"}}
 ];
component.set("v.data", data);


By this code something like this picture is shown and cannot edit relational record.
User-added image

I would like to make inline edit like attached.

User-added imageThnak you in advance.

NagendraNagendra (Salesforce Developers) 
Hi Umesin,

Sorry for this issue you are facing.

Salesforce provides documentation for inline editing of data tables here: Thanks,
Nagendra