This page explains what map fields are and how to query them.
attributes.custom
map field. The reason is that instrumentation libraries can add hundreds or even thousands of arbitrary attributes to spans. Storing each custom attribute in a separate field would significantly increase the number of fields in your dataset. To keep the number of fields in your dataset under control, Axiom places all custom attributes in the single attributes.custom
map field.
http.protocol
property inside the attributes.custom
map field to filter results:
map_field_name
. For more information on syntax, see Access properties of nested mapsAXIOM_DOMAIN
with api.axiom.co
if your organization uses the US region, and with api.eu.axiom.co
if your organization uses the EU region. For more information, see Regions.Replace API_TOKEN
with the Axiom API token you have generated. For added security, store the API token in an environment variable.Replace DATASET_NAME
with the name of the Axiom dataset where you want to send data.Replace MAP_FIELD
with the name of the field that you want to change to a map field.'
or "
) and square brackets ([]
). For example:
where ['map_field']['property1']['property2'] == 14
where map_field.property1.property2 == 14
where ['map_field'].property1.property2 == 14
), dots (.
), or dashes (-
), you can only use index notation for that entity. You can use dot notation for the other entities. For example:
where ['map.field']['property.name1']['property.name2'] == 14
where ['map.field'].property1.property2 == 14
attributes.custom
map field. You can access them as ['attributes.custom']['header.Accept']
, for example. In this case, you don’t access the Accept
field nested within the header
field. What actually happens is that you access the field named header.Accept
within the attributes.custom
map field.geo
is initially not a map field.
['geo.city']
or ['geo.country']
.
geo
to a map field through the UI or the API.
geo
parent map field. You can access the subfields as ['geo']['city']
and ['geo']['country']
.
['geo.city']
and ['geo.country']
) and the subfields of the map field (['geo']['city']
and ['geo']['country']
) as separate fields and doesn’t maintain a relationship between them.
['geo.city']
access a field literally named geo.city
, while ['geo']['city']
accesses the city
key inside a geo
map. These references are not equivalent.