0

Let's consider an example data model with two objects connected with a relationship as follows:

enter image description here

A general request is to make it possible to build any type of report that could list Custom Objects B together with their Custom Objects A. Please note the (Text) indication - due to the polymorphic relationship between Custom Object A and other objects that it can work with, this cannot be a Lookup.

The most solid option that I came up with is to incorporate a junction object with additional development to automate building it upon creating Custom Object A's record.

However, the problem is connected with a managed package, and I am looking for some development-free possibilities to limit the complexity of the final solution. Therefore, I intend to keep the package-dependent part of the system staying as simple as possible.

I tried to find a way of building reports based on External IDs, but with no success.

Are there any other options that come to your mind?

Edit: I have tried the Joined Reports approach, but without a common field like a relationship to a common object it does not work. Linking records manually is not acceptable in this case (for instance, by creating a Lookup field / junction object and manually filling it up by end-user, knowing the target record's ID).

8
  • 1
    Just to check.. are Joined Reports not applicable in your case? I thought they work on not only lookup fields. Feb 15, 2022 at 14:49
  • Does this answer your question? Need help understanding joined reports
    – identigral
    Feb 15, 2022 at 17:13
  • @Dextersecret I'm not sure whether joined reports are a suitable solution here. From SF Docs: "You can add report types to a joined report if they have relationships with the same object or objects [...]". There is no common object that could be a link and when trying to create a joined report based on CustomObjectA, after selecting CustomObjectB for join I receive the following message: "Choose a different report type. This one has no common fields with the other report types in this joined report." But maybe I just don't fully get how it works. Feb 15, 2022 at 17:30
  • @identigral please see my comment above Feb 15, 2022 at 17:30
  • 1
    Yes, it'd have to be created somehow. If this managed package is yours, you can create the junction object when the customer (subscriber) installs your package. Alternatively, don't use Reports. Allow the customer to configure/create this 'report' via custom 'report definition' screens you provide and then have a 'report' page that dynamically outputs the requested info in a tabular format.
    – identigral
    Feb 15, 2022 at 17:53

0

You must log in to answer this question.

Browse other questions tagged .