Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Hi guys,
Having trouble to find a solution for this. When run a Python query in my normal IDE i get the proper result:
Well Name | Phase | Value | UNIVERSITY 20 PW 2502H | INT | 52.75
TIGER 55-2-12 LOV 8H | MNH | 58.25
UNIVERSITY 20 TG UNIT | SRF | 25.50
but in PBI i am getting just:
52.75
58.25
25.50
Without the index in my first picture. using the following code, do you know how i can get my normal answer with all index?
condition1 = df[df['Actual Operation']=='DRL']
condition1=pd.DataFrame(condition1.groupby(by=['Well Name', 'Phase'])['Sum of Activity Time (Hr)'].sum())
condition1=condition1[condition1.isin(condition1.groupby(['Phase']).min()['Sum of Activity Time (Hr)'].tolist())].dropna()
Thanks
Solved! Go to Solution.
@Anonymous ,
If you modify the last line like below, will the output be a table, not just a column?
condition1=condition1.isin(condition1.groupby(['Phase']).min()['Sum of Activity Time (Hr)'].tolist())
If this issue persists, please share sample data and complete python code.
Community Support Team _ Jimmy Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
@Anonymous ,
If you modify the last line like below, will the output be a table, not just a column?
condition1=condition1.isin(condition1.groupby(['Phase']).min()['Sum of Activity Time (Hr)'].tolist())
If this issue persists, please share sample data and complete python code.
Community Support Team _ Jimmy Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 61 | |
| 44 | |
| 41 | |
| 36 | |
| 21 |
| User | Count |
|---|---|
| 176 | |
| 120 | |
| 106 | |
| 77 | |
| 52 |