From b35d9e258a4da981548e6237c04269d1acfea6e7 Mon Sep 17 00:00:00 2001 From: Ivan Vasechko Date: Tue, 26 Dec 2023 14:34:16 +0200 Subject: [PATCH] Update querying-child-documents-by-parent.md There is no keyword mapping for the department index (from lesson 91), so the current queries return empty set of data when using a term query for searching by keyword --- Joining Queries/querying-child-documents-by-parent.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Joining Queries/querying-child-documents-by-parent.md b/Joining Queries/querying-child-documents-by-parent.md index efe6e17..2c4a06c 100644 --- a/Joining Queries/querying-child-documents-by-parent.md +++ b/Joining Queries/querying-child-documents-by-parent.md @@ -9,8 +9,8 @@ GET /department/_search "has_parent": { "parent_type": "department", "query": { - "term": { - "name.keyword": "Development" + "match": { + "name": "Development" } } } @@ -28,11 +28,11 @@ GET /department/_search "parent_type": "department", "score": true, "query": { - "term": { - "name.keyword": "Development" + "match": { + "name": "Development" } } } } } -``` \ No newline at end of file +```