Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

grouping orders

Hello  Community  -     I have what I think is a simple question.    Using the calculated column formula below, my goal is to assign categories to Orders based on the total value of the order.    H...
  • amitchandak's avatar
    6 years ago

    Anonymous , You need to have order-level sum, inside this formula or as a new column.

     

    example, both as new columns

    order sum = sumx(filter('Shipped', [order no] = earlier([order no] )),[Shipped Price] )

     

    Shipment Category =
    switch( true(),
    'Shipped'[order sum ] <= 40000,"Quick Ship",
    'Shipped'[order sum ] < 100000,"10 Day",
    "30 Day"
    )