---
title: Query Component
slug: lowcode-en/query-component
description: Learn how to effectively use Query Components with this comprehensive document. Discover how these automated resources can effortlessly extract data through queries in the Database, and how they can function as lookup objects in forms. Follow the step-by-
docTags: 
createdAt: 2022-11-22T18:50:27.000Z
---

**Query Components** are automated resources that also abstract data through queries in the Database. They can also be used as lookup objects (Select) in forms.

## Procedure

::::WorkflowBlock
:::WorkflowBlockItem
Access the functionality through the navigation menu `Management > Query Component`.
:::

:::WorkflowBlockItem
To register a new Query Component resource, click on the "**Create**" button.
:::

:::WorkflowBlockItem
Provide the **Name, Description, Project**, and **Database Connection**.

![](https://api.archbee.com/api/optimize/pu5VMc-2TW3GQX4ly5Xp7/7-9ASz73kqu4HGn-L6QrC_image.png)
:::

:::WorkflowBlockItem
Click on **"Add"** to include fields from the table.
:::

:::WorkflowBlockItem
Provide the name of the column in the database, data type, Object attribute name, Description, Mask (if any), Width %, Angular Filter, Tooltip, and HTML.

| **Item**       | **Description**                                                                                                                                                                      |
| -------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| Mask           | An input mask. When using a mask, the field needs validation or organization of what is entered. In the case of CPF, the mask would only allow real CPFs to be entered in the field. |
| Width          | Width size of the column being configured.                                                                                                                                           |
| Angular Filter | Used when filtering specific information. For example, if you need to filter SQL query information by the age of students.                                                           |
| Tooltip        | A hint about what the object means when hovering the mouse over it.                                                                                                                  |
| Column         | Refers to the same column present in the database.                                                                                                                                   |
| Expression     |                                                                                                                                                                                      |
| Type           |                                                                                                                                                                                      |

![](https://api.archbee.com/api/optimize/pu5VMc-2TW3GQX4ly5Xp7/bTGz9XFatBplfVxqKCdJB_image.png)
:::

:::WorkflowBlockItem
As this involves SQL, it is necessary to include **FROM /  WHERE / ORDER BY \***

![](https://api.archbee.com/api/optimize/pu5VMc-2TW3GQX4ly5Xp7/dxMfPEe-CQMXWnRFCPryJ_image.png)
:::
::::

