Types/Literals
Last updated
Dasel supports the following literal types in queries.
Integers are represented as whole numbers.
1
5234
-530Note: If -530 is detected as a bad binary expression (nothing subtract 530) it can be grouped, e.g. (-530).
Numbers are interpreted as floats when they contain a decimal place . or are followed with an f.
1.1
23.45
123fBools are matched by a case insensitive match on true or false.
true
True
TRUE
false
False
FALSEStrings are a sequence of characters surrounded by quotes — both single and double quotes are supported.
The null literal represents an absent or empty value.
null is returned by functions like first and last on empty arrays, and is the fallback trigger for the ?? coalesce operator.
Array literals are defined with square brackets. See Arrays/slices for full documentation.
Object/map literals are defined with curly braces. See Objects/maps for full documentation.
Last updated
"I am a string"
'I am a string'
"I am a string with an escaped \" inside of me"null[1, 2, 3]
["a", "b", "c"]
[1, "mixed", true, null]{"name": "Tom", "age": 30}