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
Robert_S_HarperRobert_S_Harper 

Linking tables on reports

We've added custom fields, Topic__c and Sub_Topic__c to the Case object. I created an object I'm calling CaseQuestion__c and it has matching Topic__c and Sub_Topic__c fields. I'd like to link from the Case object to the CaseQuestion__c object using the values in these fields. I've not been able to do this so far and don't understand linking as described in the documents. This would be very simple in SQL but SOQL doesn't handle relationships like this.

 

I've kind of worked around it by adding a reference field and then adding formula fields to the Case object that gather the falues from the CaseQuestion__c object. It works but I'm not fond of it because it seems to be just creating reduntant fields in the database and uses up some of the field qota.

 

Is there a better way to do this or is SalesForce just not set up to do this well? It seems odd to me because most of my work with SQL was in creating relations exactly like this for reporting and analysis.

Best Answer chosen by Admin (Salesforce Developers) 
Robert_S_HarperRobert_S_Harper

I haven't found a good way to do this. I ended up just creating a reference field to the second table then formula fields that used that reference to gather data from the second table.