A context entry
& key
are defined by the following grammar (cf DMN v1.2, page 111, Section 10.3.1.2)
60. context entry = key , ":", expression;
61. key = name | string literal;
Consider the following instance of a context object
{ "12" : "hello" }
How do I access "hello"
from such an object?
Could this be an issue in the grammar? Not sure if this kind of accession is valid.
Accordingly to DMN specification, as "12" cannot be transformed into a legal name I concur with you, cannot be accessed with the dot operator.
But you can use the built-in function
get value()
as for the spec:For example:
this is valid FEEL and would result in
"hello"
.I see no issue in the grammar. I believe the only way to access this entry value is by using the built-in function.