Forum Discussion

salafoo's avatar
salafoo
Helper I
8 years ago
Solved

How to add data on a linear graph by two date

Hello All

 

I have a table of which has three columns

A) Application Number

B) Submission Date

C) Approval Date 

 

I want to make a graph as same as the below graph (Counting the number of submitted vs. approved application per month) - Graph Source: PowerPoint 

 

Graph

 

Thank you in advance

  • Hello,

     

    The typical way of handling this is to have a Date table, and create

    • An active relationship between one of your date columns (say Submission Date) and the Date table
    • And an inactive relationship between the other date column (say Approval Date) and the Date table

    Assuming the active relationship is with Submission Date, you would create measures something like this using USERELATIONSHIP to activate the inactive relationship (I'm assuming COUNTROWS makes sense as a measure):

     

    Submissions Count =
    COUNTROWS ( Submissions )
    
    Approval Count =
    CALCULATE (
        COUNTROWS ( Submissions ),
        USERELATIONSHIP ( Submissions[Approval Date], 'Date'[Date] )
    )

    See these two pages for good explanations:

    https://exceleratorbi.com.au/multiple-relationships-between-tables-in-dax/

    https://blog.enterprisedna.co/2017/10/16/working-with-multiple-dates-in-power-bi/

3 Replies

  • Hello,

     

    The typical way of handling this is to have a Date table, and create

    • An active relationship between one of your date columns (say Submission Date) and the Date table
    • And an inactive relationship between the other date column (say Approval Date) and the Date table

    Assuming the active relationship is with Submission Date, you would create measures something like this using USERELATIONSHIP to activate the inactive relationship (I'm assuming COUNTROWS makes sense as a measure):

     

    Submissions Count =
    COUNTROWS ( Submissions )
    
    Approval Count =
    CALCULATE (
        COUNTROWS ( Submissions ),
        USERELATIONSHIP ( Submissions[Approval Date], 'Date'[Date] )
    )

    See these two pages for good explanations:

    https://exceleratorbi.com.au/multiple-relationships-between-tables-in-dax/

    https://blog.enterprisedna.co/2017/10/16/working-with-multiple-dates-in-power-bi/

  • Hello all,

     

    I have a table of which has three columns:

    A) Application Number

    B) Submission Date

    C) Approved Date

     

    I need your help in creating a graph to compare the submitted vs approved application per month as same as the below 'PowerPoint' graph. 

     

     

    Thank you in advance.

    • salafoo's avatar
      salafoo
      Helper I
      Sorry guys, I reposted the topic as I thought the first one was not posted successfully, so you will notice that i have the same topic twice.