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
jogutier
Employee
Employee

how to combine two different filters to create a single one from those two

Hi,

I am using data that comes from a server to create my Power BI therefore flexibility is not that much.  I need to combine two filters that comes from that database and convert them into a single one.

Is there any way to do that?

Can I create a new filter to my Power BI using those two filters that come from the database and use it in my dashboard? 

1 ACCEPTED SOLUTION

Aha! I understand completely now. Unfortunately, you cannot do that in the service.  What you need to do is to use Excel or Power BI Desktop to connect to that data source and import it into your model. You can either created a calculated column as part of the query using "M" code or you can create a calculated column or measure as part of your Excel or Power BI Desktop data model. Then, you would upload the Excel file or Power BI Desktop file and you would have your combined field.


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

View solution in original post

7 REPLIES 7
andre
Memorable Member
Memorable Member

@jogutier I suspect that you may be trying to combine two query results into one.  If i am correct, the way to do it is to use the Append feature of Power Query.  Append will effectively join two different Power Queries into one regardless of the sources for the initial Power Queries which might give you the flexibility that you are looking for.

Greg_Deckler
Super User
Super User

No idea unless you supply some sample data and examples of these filters.

 

That being said, there are nearly endless possibilities for filtering, slicing and dicing in Power Query and Power BI using M code and DAX so the answer is probably yes..


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

@Greg_Deckler @andre

Thanks for replying.  Sorry if I'm not explaining myself correctly but even though I do work for Microsoft I work as a controller for one of our segments (Finance) and I am not technical at all! 🙂

I am using a database that connects to an SQL Server that the company uses called ARRTT.  From there comes all my filters.  Now I have data from actuals and data from pipeline as two separate filters.  What I want to do it to be able to sum both filters.  How can I do that?

 

Something else now that I have the expects 🙂 I went into the report today and even though my data has been refresh (automatically from that SQL server), the number in the dashboard has not changed.  Isnt it supposed to change automatically ones the report change?

 

I wish I could share a printscreen with you so that it is easier to understand but for obvious confidential issues (I work with numbers), I cant.

@jogutier

I'm thinking that the word filters is what is throwing a wrench into things.

 

When you say you have data from actuals and data from pipeline as two separate filters, do you mean that you have two different queries that pull this information such that they end up in two tables in the data model. Or, do you mean that they are two different columns in the same table? Or something else?

 

Let's wait on answering the question about summing both filters until I get an answer on above.


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

@Greg_Deckler my apologies again for using wrong terminology.  I think I am referring to "Fields".

What I need is to be able to add the two "fields" from the blue boxes and convert them into just ONE.

POWERBI.PNG 

Aha! I understand completely now. Unfortunately, you cannot do that in the service.  What you need to do is to use Excel or Power BI Desktop to connect to that data source and import it into your model. You can either created a calculated column as part of the query using "M" code or you can create a calculated column or measure as part of your Excel or Power BI Desktop data model. Then, you would upload the Excel file or Power BI Desktop file and you would have your combined field.


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

Thanks for your help and patience!!!!

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.

Top Solution Authors
Top Kudoed Authors