Power BI Exchange

Please login or click SIGN UP FOR FREE to create your PowerBIUG account to join this user group.
 View Only
Expand all | Collapse all

Knowing The Number Of Days Between 1st or Nth Orders for different customers

  • 1.  Knowing The Number Of Days Between 1st or Nth Orders for different customers

    Bronze Contributor
    Posted Dec 01, 2020 11:47 AM
      |   view attached

    #DAX

    Dear Experts

     

      I need to know the Average Number of days Between Order (n) and Order (n+1) for all customers not for Particuler Customer here is an example:

    Assuming  we have (175) customers they have a range of orders requested BTW (1 - n) orders, we need only Up to (10) Orders Maximum to calculate the average No of Days BTW (1-10) as the following:
    From Ordder No                     To  Order No                  No Of Customers              Average No Of Days BTW Orders
         1                                                 2                                      100                                     22.3
         2                                                 3                                        70                                      33.3
         3                                                 4                                        65                                     10.7
    ,

    ,

    ,

       9                                                  10                                       40                                        15.3

    I attached PBix Sample with this thread.



    ------------------------------
    ‪Mohammad Al-Mubarah‬‏
    Founder
    Riyadh
    114858109
    ------------------------------

    Attachment(s)



  • 2.  RE: Knowing The Number Of Days Between 1st or Nth Orders for different customers

    Bronze Contributor
    Posted Dec 02, 2020 02:26 AM
    Hi again

    below the scree-shot of the output:


    ------------------------------
    ‪Mohammad Al-Mubarah‬‏
    Founder
    Riyadh
    114858109
    ------------------------------