Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Varan_15
Helper III
Helper III

PI circular dependency error

Hi All,

 

I have customer tickets table like below base on entry and exit i created 2 measures (1.total hours spent  and 2. allocated sla hours) based on that i created result column which will show whether that customer within SLA, beyond SLA 

 

and then based on result i have create another measure called 3.addtional hours which will be apart from allocated sla hours how many hours customer took ( those whoever in Beyond SLA customers extra hours) 

Now i want to show that additional hours in days bucket like if one customer result beyond SLA and having additional hour 16 hours then it's under 2 day like i need to create buckets (1-2 , 3-6, 6+ ) this i want to show days bar chart with customer count under that bucket. when i tried measure / calculated column throw error Pi circular dependancy error how to achive.

example table : 

CustomerworkstepProducts EntryExitresult
11220inputnic01/08/2024 15:3501/08/2024 15:43within SLA
11220processnic01/08/2024 15:4305/08/2024 13:27within SLA
11220pendingnic05/08/2024 13:2705/08/2024 13:52within SLA
11220approvednic05/08/2024 13:5206/08/2024 14:05within SLA
11220closednic06/08/2024 14:0506/08/2024 15:22within SLA
566060inputllc01/07/2024 15:3501/07/2024 15:43Beyond SLA
566060processllc01/07/2024 15:4305/07/2024 13:27Beyond SLA
566060approvedllc05/07/2024 13:2705/07/2024 13:52Beyond SLA
566060closedllc05/07/2024 13:5206/07/2024 14:05Beyond SLA

 

Thanks in advance !

9 REPLIES 9
Anonymous
Not applicable

Hi @Varan_15 ,

Base on your description, it seems you got the circular dependancy error when create a measure or calculated column? Could you please provide the formula of measure/calculated column which you got the error and your expected result? Later we can check it and give you a suitable solution.

In addition, you can refer the following blogs to deal with circular dependancy error.

Understanding circular dependencies in DAX - SQLBI

Avoiding circular dependency errors in DAX - SQLBI

 

Circular Dependency between Calculated Columns in ... - Microsoft Fabric Community 

Best Regards

@Anonymous ,

 

Thanks for the update, Lest say wherever Result Beyond SLA then obiouesly having addtional Hours  in the scenario the below table second customer id result is beyond SLA so measure contains 5 hours additonal i want to create calculated clumn  day bucket when i tried it's coming pi cisculart dependency error.

table :

CustomerworkstepProducts EntryExitresult
11220inputnic01/08/2024 15:3501/08/2024 15:43within SLA
11220processnic01/08/2024 15:4305/08/2024 13:27within SLA
11220pendingnic05/08/2024 13:2705/08/2024 13:52within SLA
11220approvednic05/08/2024 13:5206/08/2024 14:05within SLA
11220closednic06/08/2024 14:0506/08/2024 15:22within SLA
566060inputllc01/07/2024 15:3501/07/2024 15:43Beyond SLA
566060processllc01/07/2024 15:4305/07/2024 13:27Beyond SLA
566060approvedllc05/07/2024 13:2705/07/2024 13:52Beyond SLA
566060closedllc05/07/2024 13:5206/07/2024 14:05Beyond SLA

 

ex:

Beyond Time Bucket =
VAR testing = IF('Test'[M_Additional Hours] = BLANK(),0, DIVIDE( additionalday,8,0) )
VAR Day_Bucket = SWITCH(TRUE(),
testing <=2, 2,
testing >2 && testing <5, 5,
testing >5 && testing <10, 10,
11)
RETURN
Day_Bucket

 

for the testing expected result will be 2 day should show 1 count  ( as we have 5 hours additional hours so divide by 8 will be 0.6 then its under <2 days bucket) .

 

Kindly suggest.

Hi All,

 

Can anyone help on this issue how to achive to create calculated column using measures without PI circular dependancy.

 

Thanks in advance 
Varan

Anonymous
Not applicable

Hi @Varan_15 ,

I created a sample pbix file(see the attachment), please check if that is what you want.

Beyond Time Bucket =
VAR additionalday =
    CALCULATE (
        SUM ( 'Test'[M_Additional Hours] ),
        FILTER ( 'Test', 'Test'[result] = "Beyond SLA" )
    )
VAR testing =
    IF (
        NOT ( ISBLANK ( 'Test'[M_Additional Hours] ) ),
        DIVIDE ( additionalday, 8, 0 )
    )
VAR Day_Bucket =
    SWITCH (
        TRUE (),
        testing <= 2, 2,
        testing > 2
            && testing < 5, 5,
        testing > 5
            && testing < 10, 10,
        11
    )
RETURN
    IF ( NOT ( ISBLANK ( 'Test'[M_Additional Hours] ) ), Day_Bucket )

vyiruanmsft_0-1730714031290.png

Best Regards

@Anonymous ,

 

Thanks for your effort, please note M_additional_Hours field is a measure and when i used the same again getting same error.
as below calculated column :

Beyond Time Bucket =
VAR additionalday =
CALCULATE (
'Final'[M_Additional Hours],
FILTER ( 'Final', 'OM_TI Final'[M_SLA_Result] = "Beyond SLA" )
)
VAR testing =
IF (
NOT ( ISBLANK ( 'Final'[M_Additional Hours] ) ),
DIVIDE ( additionalday, 8, 0 )
)
VAR Day_Bucket =
SWITCH (
TRUE (),
testing <= 2, 2,
testing > 2
&& testing < 5, 5,
testing > 5
&& testing < 10, 10,
11
)
RETURN
IF ( NOT ( ISBLANK ( 'Final'[M_Additional Hours]) ), Day_Bucket )

 

error:
<pi>A circular dependency was detected: Final[Beyond Time Bucket].</pi>

Anonymous
Not applicable

Hi @Varan_15 ,

Please update the formula of measure [Beyond Time Bucket] as below and check if it can return the correct result...

Beyond Time Bucket = 
VAR additionalday =
  SUMX(
       FILTER ( 'Test', 'Test'[result] = "Beyond SLA" ),
       [M_Additional Hours]
    )
VAR testing =
    IF (
        NOT ( ISBLANK ( 'Test'[M_Additional Hours] ) ),
        DIVIDE ( additionalday, 8, 0 )
    )
VAR Day_Bucket =
    SWITCH (
        TRUE (),
        testing <= 2, 2,
        testing > 2
            && testing < 5, 5,
        testing > 5
            && testing < 10, 10,
        11
    )
RETURN
    IF ( NOT ( ISBLANK ([M_Additional Hours] ) ), Day_Bucket )

vyiruanmsft_0-1730789518207.png

Best Regards

@Anonymous ,

 

Thanks for the update, But still no luck having same error.

 

Please note for your information i have some more calculated columns and measures in the same table is that causing this error but while getting error it's not showing any particular column/ measure names.

 

Thanks,

Anonymous
Not applicable

Hi @Varan_15 ,

Could you please share your pbix file(exclude the sensitive info) with us? We will then be able to investigate the cause of the error. You can refer the following link to upload the file to the community. Thank you.

How to upload PBI in Community

Best Regards

@Anonymous ,

 

Sorry to inform that the data source conected with SQL server could not be allowed to load hence i have shared sample data above.

 

Thanks, 

Helpful resources

Announcements
July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 community update carousel

Fabric Community Update - June 2025

Find out what's new and trending in the Fabric community.