Skip to main content

Celonis Product Documentation

Using the PQL editor

Note

You're currently viewing a topic describing a Studio feature that's in limited availability. For more information, see: Studio (new experience).

For all other Studio features, see: Studio.

The PQL editor enables you to translate process-related business questions into queries, which are then executed by a custom-built query engine. This editor can now be accessed directly from your view layout builder, helping you create detailed views with your data.

PQL_editor_overview.png

For more information about PQL, see: PQL - Process Query Language

Accessing the PQL editor from a view component

You can access the PQL editor using view components where data fields can be selected by either clicking the PQL editor button directly or when adding data to a setting (such as a table column):

access_PQL_editor.png
PQL editor enhanced options

When using the PQL editor, you have the following enhanced options:

To assist you when writing PQL expressions, an interactive PQL reference library is available within the editor.

Click PQL Ref to browse the references and then click the syntax to add it to the current line in the editor.

PQL_reference_library.png

You can also access inline PQL suggestions using CTRL + SPACE within the editor:

inline_suggestions.png

The data and variables displayed in the PQL editor are imported from Knowledge Models and package variables within the same package. They can be added to the PQL editor by clicking on them (adding them without any transformations) or you can click the + icon to apply aggregate functions to the data added.

The aggregate functions include: count, count distinct, min., max., and median.

add_data_to_pql_editor.png

When using the editor to create or edit PQL expressions, you are prompted to save the result as a metric to your knowledge model. This allows the metric to then be used and referenced in other assets using that knowledge model.

To save a metric to your Knowledge Model from within the editor, click Save to:

save_as_metric_to_knowledge_model.png

You're then in Knowledge Edit Mode, giving you the ability to edit the metadata associated with the new metric and, if necessary, the option to further edit the PQL expression.

Note that the new metric must have an ID before it can be saved and added to the Knowledge Model.

knowledge_edit_mode.png

You can now execute PQL queries and see the live results within the table whenever changes are made.

Click Run PQL when prompted or use the keyboard shortcut CTRL + ENTER.

run_PQL_refresh.png

After executing the query, either the table will update with the results or you will be shown a PQL error message with further information.

In this example, there is a syntax error in line 1.

PQL_error.png
Quick filters and sorting

Click the filters icon to quickly filter your content based on data types and sources. You can also use this feature to manage how your data is sorted.

quick_filters.png
Custom formatting cheat sheet

When using custom formatting, a cheat sheet displays the options you have available for that data type:

custom_formatting_cheat_sheet.png