Forum Discussion

lawsonbe's avatar
lawsonbe
Helper I
7 years ago
Solved

subtracting two calculated columns

 

I am trying to subtract two calculated columns. I tried a simple subtraction without the Calculate and Sum as well and that gave the same circular reference error. 

  • lawsonbe's avatar
    lawsonbe
    7 years ago

    Resolved it by creating a measure for Absent and Present. Oddly, when I tried to delete the calculated column for Absent, the measures stopped working eventhough they no longer referenced the calculated absent column. Just happy I now have an accurate measure.

5 Replies

  • PattemManohar's avatar
    PattemManohar
    Community Champion

    Can you try this please...

     

    Present = Instructional_Date_Calendar[Enrolled] - Instructional_Date_Calendar[Absent]

     

    Any sample data for replicating your error will be helpful... 

    • lawsonbe's avatar
      lawsonbe
      Helper I

      Here is a screenshot of the formula you suggested. I attempted to remove some inactive relationships to see if that was the problem. That had no effect. I hope you can see some of the data on this screenshot. I really think the error has something to do with the Enrolled column being a calculated column that is based on a table that is a union of two other tables that have no relationships established. Could that be it?

       

       

      • PattemManohar's avatar
        PattemManohar
        Community Champion

        lawsonbe Still not clear, please post what is your actual input data look like and what are the calculated columns you created along with their expressions used. Anyway, you already posted what you want to see as output...