Matrix table with 2 objects

  • 1
  • Question
  • Updated 3 years ago
Hello Community,

Let's imaging I have two objects:
1) Product
2) Quantity per Year

the object 2) has a lookup toward object 1) and contains two field: Year , Quantity


Is there a way to build a table in SKUID in which i show the records of the object 2) as columns?

Example:

Image we have two products: product1 and product2
and 4 records of "quantity per year": 2 related to product1 and 2 to product2: 
     1) related to product1: year = 2014, quantity = 2
     2) related to product1: year = 2015, quantity = 4
     3) related to product2: year = 2014, quantity = 5
     4) related to product2: year = 2015, quantity = 8

Is there a way to build a table like the following?

Product Name             2014               2015
--------------------------------------------------------------
product1                          2                     4
product2                          5                     8



Thank you very much.

Gabriele
Photo of dibe84

dibe84

  • 212 Points 100 badge 2x thumb

Posted 3 years ago

  • 1
Photo of Mansour

Mansour

  • 1,932 Points 1k badge 2x thumb
The way we did it was by using UI-Only field that leverage the MODEL_LOOKUP function.

Your main model will be the Product model.  This is the model that will have all the UI-Only fields.
You will then have 1 model for each year of stats.

Examples:
Formula: VALUE(MODEL_LOOKUP("model1","countId","regionc",{{Region__c}}))