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

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
Anonymous
Not applicable

Create a new table from existing table with multiple filters

Hello, I'm trying to create a new table from an existing table, but on two columns I would like a filter applied:

Column OTIF="Y" and column DG or Config =notblank

 

I am now using the following formula, but that only includes 1 filter: SELECTCOLUMNS(FILTER('OTIF','OTIF'[Ship set flag]="Y"),"Ship set flag",OTIF[Ship set flag],"Ship set ID",OTIF[Ship set ID],"Order number",OTIF[Order Number],"DG or Config",OTIF[DG or Config])

 

Thanks for your help!

1 ACCEPTED SOLUTION
jdbuchanan71
Super User
Super User

@Anonymous 

You can apply multiple filters like this.

Table =
SELECTCOLUMNS (
    FILTER ( 'OTIF', 'OTIF'[Ship set flag] = "Y" && NOT ISBLANK ( 'OTIF'[Config] ) ),
    "Ship set flag", OTIF[Ship set flag],
    "Ship set ID", OTIF[Ship set ID],
    "Order number", OTIF[Order Number],
    "DG or Config", OTIF[DG or Config]
)

View solution in original post

3 REPLIES 3
Anonymous
Not applicable

@jdbuchanan71 

 

I have an almost similar thing, but now instead of a second filter with ISBLANK I need to add 2 filters on the same column, so in total I have 3 filters, is that possible?

FILTER(OTIF,OTIF[Ship set flag]="Y"

FILTER(OTIF,OTIF[Line status]="Awaiting_Supply"

FILTER(OTIF,OTIF[Line status]="Supply_Partial"

 

Total formula I have now but wasn't working:

Shipset Y&Line status = SELECTCOLUMNS(FILTER(OTIF,OTIF[Ship set flag]="Y") && FILTER(OTIF,OTIF[Line status]="Awaiting_Supply",

"Ship set flag",OTIF[Ship set flag],
"Ship set ID",OTIF[Ship set ID],
"Order line status",OTIF[Line status],
"Order number",OTIF[Order Number]))

@Anonymous 

That one you can do using IN.

Shipset Y&Line status =
SELECTCOLUMNS (
    FILTER ( 'OTIF', 'OTIF'[Ship set flag] = "Y" && OTIF[Line status] IN {"Awaiting_Supply", "Supply_Partial"} ),
    "Ship set flag", OTIF[Ship set flag],
    "Ship set ID", OTIF[Ship set ID],
    "Order number", OTIF[Order Number],
    "DG or Config", OTIF[DG or Config]
)
jdbuchanan71
Super User
Super User

@Anonymous 

You can apply multiple filters like this.

Table =
SELECTCOLUMNS (
    FILTER ( 'OTIF', 'OTIF'[Ship set flag] = "Y" && NOT ISBLANK ( 'OTIF'[Config] ) ),
    "Ship set flag", OTIF[Ship set flag],
    "Ship set ID", OTIF[Ship set ID],
    "Order number", OTIF[Order Number],
    "DG or Config", OTIF[DG or Config]
)

Helpful resources

Announcements
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 Power BI Update Carousel

Power BI Monthly Update - June 2025

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

June 2025 community update carousel

Fabric Community Update - June 2025

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