Custom Object Report Chart Components

Here’s something I just took an inordinate amount of time researching, then quickly cobbled together the solution. The request is to add a Report Chart Component to an Account Page layout to show data on a custom related object. Most of the information I saw online for adding a report chart component to a record was predicated on there being a natural relationship between the standard objects – i.e. how to show Number of Opportunities on an Account. In my case, I needed to show Number of Custom Records on Account. There was an easy report of the Custom Object with Account Name in it – that should work! It didn’t. There was already a relationship between the Custom Object and the Account – but the standard Custom Object report didn’t work. What does? You have to create a new Custom Report Type with Account as parent and your Custom Object as the child:

Create the new custom report type, now using this report type create your report (in my case the same report I’d created earlier on the custom object – but this time with the new custom report type):

Then on the Account Page you want to add this Report Chart Component, add it over and set the filter to be on Account ID (or whatever your parent object is):

The trick here is creating the Custom Report Type. You might have two related objects and want to show data from one object on the other. You might have standard reports for those objects – but if you want the parent object to have a Report Chart Component that automatically filters the report to just that parent record you have to first build a Custom Report Type between this Parent and Child, then create your report and add the Component. Fun!