Skip to content
This repository was archived by the owner on Nov 7, 2025. It is now read-only.

Conversation

@nablaone
Copy link
Member

@nablaone nablaone commented Mar 4, 2025

This is PR add support for querying map columns.

For example:

CREATE TABLE IF NOT EXISTS "foo"
(
    "@timestamp" DateTime64 DEFAULT now64(),
    `bar` Map(String, Nullable(String))
)
ENGINE = MergeTree
ORDER BY ("@timestamp");        

insert into foo values ('2020-01-01 00:00:00', {'a': 'b'});
insert into foo values ('2020-01-01 00:00:00', {'c': 'd', 'e': 'f'});
insert into foo values ('2020-01-01 00:00:00', {'g': 'h', 'i': 'j', 'k': 'l'});

We can access the value of the map by using fieldname.key syntax

{
    "query": {
        "bool": {
            "must": [
                {
                    "match": {
                        "bar.a": "b"
                    }
                }
            ]
        },
        "match_all": {}
    }
}

@nablaone
Copy link
Member Author

nablaone commented Mar 4, 2025

/run-integration-tests

@nablaone nablaone closed this Mar 4, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants