Bound Names Reference

Inside a QL expression, there are a few special "variables" that you can use. They aren't exactly functions (so they don't show up in the Function Reference), but they can be useful when you are constructing complex expressions. These bound names provide special access to what's going on in your expression.
  • $_context -- this is by far the most commonly-useful bound name. It produces the value that was passed in to the beginning of this expression; in practice, it usually contains the Thing that you are looking at. (However, when you get into complex nested expressions, this will not necessarily be the case.)
  • $_defining -- if you call a function like myProp.func(), then myProp is known as the defining function inside of func(). This can be useful when building fancy functions that use this dotted syntax, but it isn't often useful otherwise.
  • $_1, $_2, etc -- if this function was called with parameters, those parameters can be accessed using these bound names.
See More about QL for more information about bound names and how to define and use them yourself.