This is a cache of https://www.elastic.co/guide/en/elasticsearch/painless/8.19/painless-identifiers.html. It is a snapshot of the page as it appeared on 2025-11-24T06:22:52.466+0000.
Identifiers | Painless Scripting Language [8.<strong>19</strong>] | Elastic
IMPORTANT: This documentation is no longer updated. Refer to Elastic's version policy and the latest documentation.

Identifiers

edit

Use an identifier as a named token to specify a variable, type, field, method, or function.

Errors

If a keyword is used as an identifier.

Grammar

ID: [_a-zA-Z] [_a-zA-Z-0-9]*;

Examples

  • Variations of identifiers.

    a
    Z
    id
    list
    list0
    MAP25
    _map25
    Map_25