cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
SINDUCHOW
Frequent Visitor

FILTER 2 COLUMNS AT THE SAME TIME

Hi,

 

I built gallery on oracle table and currently filtering on one column which  is a primary key. I would like my app to filter on 2 columns. double filtering on same table and 2 columns.

I tried using this and it does not work 

Filter('[POC].[VIATRM_BILLING]',StartsWith(PID,TextSearchBox1_1.Text) And EndsWith(PROGRAM_ID,TextSearchBox1_1.Text))

 

thanks,

yernenis

1 ACCEPTED SOLUTION

Accepted Solutions

Hi @SINDUCHOW :

Do you want to search records based on this string?

The key is to use correct syntax. In the StartsWith function and EndsWith function, the first parameter should be the string to be tested, and the second parameter is the head/tail characters.

Please try this formula:

Filter('[POC].[VIATRM_BILLING]',StartsWith(TextSearchBox1_1.Text,PID) And EndsWith(TextSearchBox1_1.Text,PROGRAM_ID))

I think this link will help you a lot:

https://docs.microsoft.com/en-us/powerapps/maker/canvas-apps/functions/function-startswith

Best Regards,

Bof

 

View solution in original post

4 REPLIES 4
mdevaney
Super User
Super User

@SINDUCHOW 

It appears you have already achieved this.  Are you having an issue?  Are you receiving errors?

 

---
Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

@mdevaney 

 

No issues but when I play it and filter, it does not give an out.

this is how my data looks 

SINDUCHOW_0-1600804268752.png

 

when I filter I use  first column and second combined and it gives no result. kindl suggest if I am missing something here

 

 

SINDUCHOW_1-1600804451907.png

 

 

Hi @SINDUCHOW :

Do you want to search records based on this string?

The key is to use correct syntax. In the StartsWith function and EndsWith function, the first parameter should be the string to be tested, and the second parameter is the head/tail characters.

Please try this formula:

Filter('[POC].[VIATRM_BILLING]',StartsWith(TextSearchBox1_1.Text,PID) And EndsWith(TextSearchBox1_1.Text,PROGRAM_ID))

I think this link will help you a lot:

https://docs.microsoft.com/en-us/powerapps/maker/canvas-apps/functions/function-startswith

Best Regards,

Bof

 

View solution in original post

SINDUCHOW
Frequent Visitor

@v-bofeng-msft 

Thank you for your reply!!

It worked but shows delegation warning, do we need to make any more changes !!

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Top Solution Authors
Top Kudoed Authors
Users online (1,856)