Dictionary Table Engine
As an example, consider a dictionary of products
with the following configuration:
Query the dictionary data:
SELECT
name,
type,
key,
attribute.types,
bytes_allocated,
element_count,
source
FROM system.dictionaries
This view isn’t helpful when you need to get raw data, or when performing a JOIN
operation. For these cases, you can use the Dictionary
engine, which displays the dictionary data in a table.
Syntax:
CREATE TABLE %table_name% (%fields%) engine = Dictionary(%dictionary_name%)`
Ok
Take a look at what’s in the table.
┌────product_id─┬─title───────────┐
└───────────────┴─────────────────┘