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

I want to create a lightning component in which I want to show the the details for a master detail object child-parent relation.

I have an Object which is n master-detail with another object 
When A record in object A is created 3 records are created in Object b automatically.(I did this through process builder)
I want to put the component on object A to show all the associate record of object B and billing details of it.

Thanks in Advance!

viswanath reddy 53viswanath reddy 53
 Hi Nyshaa,

It looks like our team of experts can help you resolve this ticket.
We have Salesforce global help-desk support and you can log a case and our Customer Success Agents will help you solve this issue. You can also speak to them on live chat. Click on the below link to contact our help-desk. Trust me it is a support service that we are offering for free!

Jarvis SFDC team
Barthelemy Laurans 1Barthelemy Laurans 1

You can use the related list feature.

If you really need specific control over the list displayed, you can create a custom LWC or Aura component and query the related records using the relationship queries ( for example.

Best regards,
Sumana R 15Sumana R 15
Hello everyone, 
I am trying to create a component that accepts 'n' number of case numbers as comma saperated values and a picklist field named Status. Once the user clicks on Update case status button, the status of all the selected case numbers must be updated as per the value selected in the picklist

The code is saved but i am getting error on click on the update status button. 

<aura:component implements="flexipage:availableForAllPageTypes" access="global" controller="CaseStatusUpdateClass">
    <aura:attribute name="userList" type="List"/>
    <aura:attribute name="caseNo" type="String"/>
    <ui:inputTextArea aura:id="caseno" label="Enter Case numbers" value="Enter Case numbers" rows="5"/>
    <aura:attribute name="caseStatusAtt" type="String"/>
    <div class="row">
        <p class="title">Select Case Status: </p>
    	<ui:inputSelect class="Single" aura:id="CaseStatus">
            <ui:inputSelectOption text="In Progress"/>
            <ui:inputSelectOption text="Closed"/>
            <ui:inputSelectOption text="Working"/>
            <ui:inputSelectOption text="Escalated"/>
            <ui:inputSelectOption text="None"/>
    <ui:button class="button" label="Update Case Status" press="{!c.setStatus}"/>
Controller JS:
	setStatus : function(component, event, helper) {
        var caseno = component.find("caseno").get("v.value");
        var status = component.find("caseStatusAtt").get("v.value");
	CaseStatusUpdateClass : function(component, event, helper) {
        var caseno = component.get("v.caseNo");//here we are getting the case number we entered
        var action = component.get("c.getcasenew");//here we calling apex method
        action.setParams({ caseno1 : caseno, CaseStatusToSet : CaseStatus });
        action.setCallback(this, function(response){
            var state = response.getState();

Apex class:
public class CaseStatusUpdateClass {
    public String caseno {get; set;}
    public String CaseStatus {get; set;}
    public static String getcasenew(String caseno1, String CaseStatusToSet){
        String status = CaseStatusToSet;
        // you need to create another list for updation --just add the case in that list and then update
        string caseNum = caseno1;
        List<Case> caseupdate = new List<Case>();
        List<Case> existingCaseList = [Select id from case where CaseNumber =:caseno1];
        for(Case c : existingCaseList){
           Case cc = new Case();
            cc.Id =;
            cc.Status = status;
        //always check for null - best practise
        if(caseupdate!=null && !caseupdate.isEmpty()){
            update caseupdate;
        	return 'Updated successfully';
            return 'Test error';

Please help
Barthelemy Laurans 1Barthelemy Laurans 1
@Sumana R 15 : could you ask your question in a separated post ?