Skip to main content

Anatomy of a DPQL query

in DPQL Reference
Authors list
Published: 23 Mar 2018|Last updated: 3 Nov 2022

Once you have selected to edit or build a new stat, the stat builder gives you both a guided process, as well as raw DPQL.

DPQL queries consists of a series of clauses:

  • SELECT select expression

  • FROM database table

  • [WHERE conditions]

  • [SPLIT BY split fields]

  • [GROUP BY group fields]

  • [ORDER BY order fields]

  • [LIMIT amount [OFFSET offset amount]

  • [LAYER WITH another query]

  • [IN subquery]

  • [UNION another subquery]

Clauses in [square brackets] are optional.

Italic text is a placeholder for a value that you enter.**

Note


If you want your query to refer to a particular item (e.g. one of your departments), you will often refer to the item by its ID number.

HelpfulUnhelpful

0 of 1 people found this page helpful

Pages in Anatomy of a DPQL query

SELECT
Authors list
Published: 22 May 2018
Last updated: 3 Nov 2022
FROM
Authors list
Published: 16 Mar 2017
Last updated: 3 Nov 2022
WHERE
Authors list
Published: 23 Mar 2018
Last updated: 3 Nov 2022
SPLIT BY
Authors list
Published: 16 Mar 2017
Last updated: 3 Nov 2022
ORDER BY
Authors list
Published: 23 Mar 2018
Last updated: 3 Nov 2022
LIMIT / OFFSET
Authors list
Published: 16 Mar 2017
Last updated: 3 Nov 2022
LAYER WITH
Authors list
Published: 23 Mar 2018
Last updated: 3 Nov 2022
IN
Authors list
Published: 23 Mar 2018
Last updated: 3 Nov 2022
UNION
Authors list
Published: 23 Mar 2018
Last updated: 3 Nov 2022
next pageGeneral Expression Format
previous pageMaking a Report

Please log in or register to submit a comment.