Power FX - Search Function Tutorial

Unlock the power of data manipulation with our tutorial on the 'search function'! Discover how to effectively use lookup, search, and filter functions in Power FX for your low-code applications. Learn through real examples that enhance user experience by efficiently extracting and managing information. Join us for insights that boost your skills in no time!

  • 03:42
  • 201 views
00:00:06
search,
00:00:06
and filter functions are essential tools and power effects
00:00:09
for manipulating and interacting with data in your applications.
00:00:13
They allow you to search,
00:00:15
filter,
00:00:16
and extract specific information from a table or collection.
00:00:20
In this tutorial,
00:00:21
we will explore these functions through simple examples
00:00:24
to help you understand and use them effectively.
00:00:28
The lookup function returns the first record in a
00:00:30
table or collection that matches a given condition.
00:00:33
It is ideal when you need to retrieve a specific value based on a criterion.
00:00:38
Let's imagine we have a list of products called products with the columns,
00:00:42
product name,
00:00:43
price,
00:00:44
and category.
00:00:45
We want to display the price of a product based on
00:00:48
the name entered by the user in a text box.
00:00:50
For this,
00:00:51
we use the following formula.
00:00:53
Products is the data source containing the products.
00:00:56
The product name must match the value entered by the user in the input field.
00:01:01
This is the condition to find the product
00:01:04
whose name matches the one entered by the user.
00:01:07
Price is the field we want to retrieve from the found record.
00:01:11
Thus,
00:01:11
the formula returns the price of the product
00:01:13
whose name was entered by the user.
00:01:16
Next,
00:01:17
the search function allows you to search for a string in
00:01:19
a table or collection by examining one or more columns.
00:01:23
It is particularly useful for implementing keyword search.
00:01:27
We have a list of contacts called contacts with the column's title,
00:01:31
last name,
00:01:32
and city.
00:01:34
We want to allow the user to search for contacts
00:01:36
based on a keyword entered in this input field.
00:01:39
The formula to use is as follows.
00:01:42
Contax is the data source containing the contacts.
00:01:46
This retrieves the keyword entered by the user.
00:01:49
Title.
00:01:50
Last name and city are the columns in which to perform the search.
00:01:54
Thus,
00:01:54
the formula returns a table of contacts whose name,
00:01:58
first name,
00:01:59
or city contains the entered keyword.
00:02:04
The filter function is used to filter a table or collection
00:02:07
based on one or more conditions.
00:02:10
It allows you to display only the data that meets certain criteria.
00:02:14
Suppose you have a collection of tasks called tasks
00:02:17
with the columns title,
00:02:19
status,
00:02:19
and priority.
00:02:21
We want to allow the user to search for tasks based on their status.
00:02:24
The formula to use is as follows.
00:02:28
Tasks is the data source containing the tasks.
00:02:31
This is the condition to filter the tasks.
00:02:34
Thus,
00:02:34
the formula returns a collection of tasks that
00:02:37
match the criteria entered by the user.
00:02:41
To further refine the results,
00:02:43
it is possible to combine these functions.
00:02:46
For example,
00:02:47
we want to display contacts who live in the city entered by the
00:02:50
user in an input field that we will call text input city,
00:02:54
whose name or first name matches the keyword entered
00:02:57
in another input field called Text input search.
00:03:00
The corresponding formula is as follows.
00:03:04
The search formula
00:03:06
searches for contacts whose name or first name
00:03:09
contains the enter keyword.
00:03:11
Filter
00:03:12
then refines the results to include only those
00:03:14
residing in the city specified by the user.
00:03:17
Thus,
00:03:18
the formula returns the contacts that match the keyword
00:03:21
and live in the specified city.
00:03:25
In conclusion,
00:03:26
understanding and using the lookup,
00:03:28
search,
00:03:28
and filter functions in Power FX
00:03:31
is essential for creating powerful and interactive applications.
00:03:35
These functions allow you to manipulate data efficiently,
00:03:38
thus providing an enriched user experience.

No elements match your search in this video....
Do another search or back to content !

 

00:00:05
A pesquisa,
00:00:06
pesquisar,
00:00:06
e as funções de filtro são ferramentas essenciais e efeitos de potência
00:00:09
para manipular e interagir com dados nas suas aplicações.
00:00:13
Permitem-lhe pesquisar,
00:00:15
filtro,
00:00:16
e extrair informações específicas de uma tabela ou colecção.
00:00:20
Neste tutorial,
00:00:21
exploraremos estas funções através de exemplos simples
00:00:24
para o ajudar a compreendê-los e utilizá-los eficazmente.
00:00:28
A função de pesquisa retorna o primeiro registo num
00:00:30
tabela ou colecção que corresponda a uma determinada condição.
00:00:33
É ideal quando precisa de recuperar um valor específico com base num critério.
00:00:38
Vamos imaginar que temos uma lista de produtos chamados produtos com as colunas,
00:00:42
nome do produto,
00:00:43
preço,
00:00:44
e categoria.
00:00:45
Queremos exibir o preço de um produto com base em
00:00:48
o nome introduzido pelo utilizador numa caixa de texto.
00:00:50
Para isso,
00:00:51
utilizamos a seguinte fórmula.
00:00:53
Produtos é a fonte de dados que contém os produtos.
00:00:56
O nome do produto deve corresponder ao valor introduzido pelo utilizador no campo de entrada.
00:01:01
Esta é a condição para encontrar o produto
00:01:04
cujo nome corresponde ao introduzido pelo utilizador.
00:01:07
Preço é o campo que queremos recuperar do registo encontrado.
00:01:11
Assim,
00:01:11
a fórmula devolve o preço do produto
00:01:13
cujo nome foi introduzido pelo utilizador.
00:01:16
Seguinte,
00:01:17
a função de pesquisa permite pesquisar uma string em
00:01:19
um quadro ou colecção examinando uma ou mais colunas.
00:01:23
É particularmente útil para implementar a pesquisa de palavras-chave.
00:01:27
Temos uma lista de contactos chamados contactos com o título da coluna,
00:01:31
apelido,
00:01:32
e cidade.
00:01:34
Queremos permitir que o utilizador procure contactos
00:01:36
com base numa palavra-chave introduzida neste campo de entrada.
00:01:39
A fórmula a utilizar é a seguinte.
00:01:42
Conax é a fonte de dados que contém os contactos.
00:01:46
Isto recupera a palavra-chave introduzida pelo utilizador.
00:01:49
Título.
00:01:50
O apelido e a cidade são as colunas nas quais efectuar a pesquisa.
00:01:54
Assim,
00:01:54
a fórmula devolve uma tabela de contactos cujo nome,
00:01:58
nome próprio,
00:01:59
ou cidade contém a palavra-chave introduzida.
00:02:04
A função de filtro é utilizada para filtrar uma tabela ou colecção.
00:02:07
com base numa ou mais condições.
00:02:10
Permite exibir apenas os dados que satisfazem determinados critérios.
00:02:14
Suponha que tem uma coleção de tarefas chamadas tarefas
00:02:17
com o título das colunas,
00:02:19
estatuto,
00:02:19
e prioridade.
00:02:21
Queremos permitir que o utilizador procure tarefas com base no seu estado.
00:02:24
A fórmula a utilizar é a seguinte.
00:02:28
Tarefas é a fonte de dados que contém as tarefas.
00:02:31
Esta é a condição para filtrar as tarefas.
00:02:34
Assim,
00:02:34
a fórmula devolve uma colecção de tarefas que
00:02:37
corresponder aos critérios inseridos pelo utilizador.
00:02:41
Para refinar ainda mais os resultados,
00:02:43
é possível combinar estas funções.
00:02:46
Por exemplo,
00:02:47
queremos exibir os contactos que residem na cidade inseridos pelo
00:02:50
utilizador num campo de entrada que chamaremos de cidade de entrada de texto,
00:02:54
cujo nome ou primeiro nome corresponde à palavra-chave introduzida
00:02:57
noutro campo de entrada chamado Pesquisa de entrada de texto.
00:03:00
A fórmula correspondente é a seguinte.
00:03:04
A fórmula de pesquisa
00:03:06
procura contactos cujo nome ou primeiro nome
00:03:09
contém a palavra-chave enter.
00:03:11
Filtrar
00:03:12
em seguida, refina os resultados para incluir apenas aqueles
00:03:14
residir na cidade especificada pelo utilizador.
00:03:17
Assim,
00:03:18
a fórmula devolve os contactos que correspondem à palavra-chave
00:03:21
e viver na cidade especificada.
00:03:25
Concluindo,
00:03:26
compreender e utilizar a pesquisa,
00:03:28
pesquisar,
00:03:28
e funções de filtro em Power FX
00:03:31
é essencial para a criação de aplicações poderosas e interactivas.
00:03:35
Estas funções permitem-lhe manipular dados de forma eficiente,
00:03:38
proporcionando assim uma experiência de utilizador enriquecida.

No elements match your search in this video....
Do another search or back to content !

 

Mandarine AI: CE QUI POURRAIT VOUS INTÉRESSER

Reminder

Show