3.2.4. Create Facts

For the Facts measure we will take the Orders and Order Lines.

  1. First, create the Order Line transformation. Drag and drop the Table input node onto the worksheet and define the fields we need for the report: id, product_id, quantity and order_id:

    star schema 7
  2. Then create an Insert/Update node for order lines:

    star schema 8
  3. Create the transformation for orders:

    star schema 9
  4. Finally, update the customers IDs in the table:

    star schema 10
  5. The Facts transformation is now ready:

    star schema 11
  6. Wrap the transformation in the corresponding job:

    star schema 13