Dual('Jan', 1)
Dual values in Power BI
Qlik fields can hold a dual value: a text and a number at the same time. Power BI columns have one data type, so you use a text column sorted by a number column (Sort by column).
Short answer: No 1:1 data type. Create two columns (Month and Month Number) and set Sort by column on the text column. Use the number column in calculations.
What it does in Qlik
Dual(text, number) creates a value that displays as text but sorts and calculates as a number. Many Qlik functions return duals, for example Month(), Date() and ApplyMap results. A typical use is month names that sort chronologically, or "Low/Medium/High" bands that sort by severity.
Qlik example
LOAD *, Dual(Text(Severity), SeverityRank) AS SeverityDual,
Month(OrderDate) AS Month // dual: 'Jan' / 1
FROM [lib://Data/tickets.qvd] (qvd);Power BI equivalent
Two columns plus Sort by column
= Table.AddColumn(Source, "Month Number", each Date.Month([OrderDate]), Int64.Type)
= Table.AddColumn(Previous, "Month", each Date.ToText([OrderDate], [Format = "MMM", Culture = "en-US"]), type text)Then in the model: select Month > Column tools > Sort by column > Month Number.
Gotchas and behaviour differences
- Sort by column requires exactly one sort value per text value. "Jan" can't map to both 1 and 13.
- DAX
FORMAT()returns text, soFORMAT([Sales], "#,0")loses its number behaviour. Use format strings (or dynamic format strings) on measures instead. - Numeric comparisons on the text column (
Month > "Mar") compare alphabetically. Use the number column.
Official documentation
- Dual - script and chart function (Qlik Help)
- Sort one column by another column in Power BI (Microsoft Learn)
- FORMAT function (DAX) (Microsoft Learn)
Related pages
Date(Date#(text, 'YYYYMMDD'), 'DD-MM-YYYY')
Date#() parsing and Date() formatting
Date#() interprets text as a date and Date() formats a number as a date, keeping it a dual. In Power BI, parse in Power Query with Date.FromText and set the display format on the column. DAX FORMAT() turns a date into text.
Partial / different approach
LOAD ... AUTOGENERATE ... WHILE ... IterNo()
Master calendar (date table)
The Qlik master calendar script maps to a date table built in Power Query (List.Dates) or DAX (CALENDAR), marked as a date table and related to the fact date. It is essential for every time-intelligence function.
Direct equivalent
ApplyMap('MapName', expr [, default])
Mapping Load and ApplyMap
ApplyMap looks up a value in a two-column mapping table during load. In Power BI, use a merge in Power Query, a record lookup, or simply a relationship with RELATED. The behaviour differs for case sensitivity, duplicates and missing keys.
Partial / different approach
Spotted an error or a better pattern? QlikToDax is maintained by a working BI consultant; corrections are welcome via the About page. Last reviewed 2026-10-25.