Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

Newbie needs Help with aging

Hello my name is Jamie. I am pretty new to power bi and data modeling in general. I would like to have a dax formula that will look at a colum name remaining balance, if the colum has data then sort it in one of three colums 30,60,90. That way I can see if a client has a balance and how far past due it is.

Thanks in advance for any help you can give.

Jamie

  • Anonymous's avatar
    Anonymous
    6 years ago

    Thanks Everyone I have figured out a solution to this issue

4 Replies

  • nandukrishnavs's avatar
    nandukrishnavs
    Community Champion

    Anonymous 

     

    Assume your table is similar to below.

    CompanySalesDate
    A10001-04-2020
    B15001-03-2020
    C20001-02-2020
    D25001-01-2020
    E30001-12-2019

     

    Create a calculated column

     

    Aging = 
    var _days=DATEDIFF(TableSale[Date],TODAY(),DAY)
    var _result= IF(_days<=30,"30",IF(_days<=60,"60","90"))
    return _result

     



    Did I answer your question? Mark my post as a solution!
    Appreciate with a kudos
    🙂

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi Anonymous ,

    Could you please provide some sample data(exclude sensitive data) and your expected result? What 30, 60 and 90 means? They are the duration between xxDate and current date?

    Best Regards

    Rena

    • Anonymous's avatar
      Anonymous
      Not applicable

      Thanks Everyone I have figured out a solution to this issue

      • Anonymous's avatar
        Anonymous
        Not applicable

        Hi Anonymous ,

        Glad to hear that you have gotten the solution for your problem. Could you please marked it as answered since the problem has been solved?

        Best Regards

        Rena