cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
MateusPereira
Level: Powered On

Finding a specific record and doing something

So I have this Table with a lot of records, and I want to find one (or more) with one specific value for a specific column, and if it exists then I want o do something. I noticed Filter, Search and LookUp don't work because they return a table and I can't do anything with it, what can I do?

2 REPLIES 2
Super User
Super User

Re: Finding a specific record and doing something

Hi @MateusPereira 

You might want to consider the use of the CountIf function.

Here's an example of the syntax you would use.

If( CountIf(UserTable, EmailAddress="tim@tim.com" ) = 0,
Navigate(NewScreen),
Navigate(EditScreen)
)

In this example, if a row doesn't exist in the UserTable with the EmailAddress  tim@tim.com, this formula navigates to a screen called NewScreen.

Community Support Team
Community Support Team

Re: Finding a specific record and doing something

Hi @MateusPereira ,

Could you decribe more clearly about your demands?

If you need a table, I suggest you use this formula: Filter(tablename,formula) 

If you need a record, Isuggest you use this formula: LookUp(tablename, formula)

If you need a value, I suggest you use this formula: LookUp(tablename,formula,fieldname)

These formulas' result is different. You need to choose according to your demands.

Here's a doc about these fucntions for your reference:

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

 

 

Best regards,

Community Support Team _ Phoebe Liu

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

Helpful resources

Announcements
firstImage

Watch Sessions On Demand!

Continue your learning in our online communities.

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

FirstImage

Power Platform World Tour

Coming to a city near you

thirdimage

PowerApps Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

FourthImage

Join PowerApps User Group!!

Connect, share, and learn with your peers year-round

SecondImage

Power Platform Summit North America

Register by September 5 to save $200

Users Online
Currently online: 184 members 4,681 guests
Please welcome our newest community members: