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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Including Same Quarter Deliveries in Same Year Deliveries

Hi,

 

I've come up with a conditional column that states if orders are booked and shipped in the same fiscal quarter (BnSQ) ,in the same fiscal year (BnSY) or normal(not in the same quarter or year). I've placed a slicer that allows the user to filter according to these three variables. The ones that are allocated BnSQ are accurate, but they dont show up when BnSY is selected. This should be the case since those booked and shipped in the same FQ, would be also booked and shipped in the same FY as well.  I understand that this is because i've created a column and the respective variables have been assigned according to the condition.

 

What i've done is:
- Create a conditional column known as "Op3" which distinguishes deals booked and shipped within the same FQ

- Create a conditional column known as "Op4" which distinguishes deals that are executed within the same FY

- Create a conditional column to assign the variable names (BnSQ,BnSY and normal) based on a few conditions.

 

Here's my code that can be found in the Advanced Editor:

   Op3 = Table.AddColumn(#"Changed Type7", "Op3", each if [Delivery Q] = [FQ] then 1 else if [Delivery Q] <> [FQ] then 2 else null),
    #"Changed Type6" = Table.TransformColumnTypes(Op3,{{"Op3", Int64.Type}, {"Delivery Year", type text}}),
    Op4 = Table.AddColumn(#"Changed Type6", "Op4", each if [FY] = [Delivery Y] then 1 else 0),
    #"BnS - Q&Y" = Table.AddColumn(Op4, "BnS - Q&Y", each if [Op3] = [Op4] then "BnSQ" else if [Op4] = 1 then "BnSY" else "Normal")

 

Any idea how i can go about solving this issue?

 

Thank you

 

 

1 ACCEPTED SOLUTION
v-eachen-msft
Community Support
Community Support

Hi @Anonymous ,

 

You could create a new column to let "BnSQ" and "BnSY" be the same value.

#"Custom" = Table.AddColumn(#"BnS - Q&Y", "Custom", each if [BnS - Q&Y] = "BnSQ" then 1 else if [BnS - Q&Y] = "BnSY" then 1 else 0)

Then you could create a new table which has slicer element and its value. Use a measure as a filter to show the right result.

Here is my test file for your reference.

 

Community Support Team _ Eads
If this post helps, then please consider Accept it as the solution to help the other members find it.

View solution in original post

1 REPLY 1
v-eachen-msft
Community Support
Community Support

Hi @Anonymous ,

 

You could create a new column to let "BnSQ" and "BnSY" be the same value.

#"Custom" = Table.AddColumn(#"BnS - Q&Y", "Custom", each if [BnS - Q&Y] = "BnSQ" then 1 else if [BnS - Q&Y] = "BnSY" then 1 else 0)

Then you could create a new table which has slicer element and its value. Use a measure as a filter to show the right result.

Here is my test file for your reference.

 

Community Support Team _ Eads
If this post helps, then please consider Accept it as the solution to help the other members find it.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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