[{"id":"elasticsearchbeginner-001","courseId":"elasticsearch-beginner","domain":"data-modeling","topic":"Index mappings","prompt":"A live index has a field named status mapped as text, and your team needs it as keyword. What does Elasticsearch need to make that change?","hint":"Consider what happens to documents that are already stored in the index.","explain":"A mapping decides how each field is indexed, and that decision shapes the data already written. Some mapping changes can be applied to a live index, while others depend on what is already stored.","source":"https://www.elastic.co/guide/en/elasticsearch/reference/current/mapping.html","interaction":{"type":"single"},"options":[{"id":"a","text":"Reindex the documents into a new index with the mapping you want","why":"Changing the mapping of an already-mapped field usually requires reindexing, because existing data was indexed under the old mapping."},{"id":"b","text":"Send the new type through the update mapping API","whyNot":"That API can add new fields and multi-fields, but in most cases it can't change the mapping of a field that is already mapped."},{"id":"c","text":"Turn on dynamic mapping so the field is detected again","whyNot":"Dynamic mapping adds fields it sees as new; it doesn't re-type a field that is already mapped."},{"id":"d","text":"Change the mapping and the stored values convert automatically","whyNot":"Existing values are not rewritten when a mapping changes, which is why such changes need reindexing."}],"answer":"a","explanation":"In most cases, the mapping of a field that is already mapped can't be changed in place; the change requires reindexing.","concept":"In most cases, the mapping of a field that is already mapped can't be changed in place; the change requires reindexing.","rev":1,"updatedAt":"2026-10-26","kind":"scenario","takeaways":["Plan field types before loading data; changing an existing field's type usually means reindexing."]},{"id":"elasticsearchbeginner-002","courseId":"elasticsearch-beginner","domain":"data-modeling","topic":"Dynamic field mapping","prompt":"With default settings, a new field that holds the string \"1.0\" is mapped as a float, because the value looks like a number.","hint":"Check whether the numeric detection setting is switched on by default.","explain":"Dynamic mapping infers a field's type from the first value it sees, and it can test strings against detection rules. Each rule comes with a default that the mapping can change.","source":"https://www.elastic.co/guide/en/elasticsearch/reference/current/dynamic-field-mapping.html","interaction":{"type":"true-false"},"options":[{"id":"a","text":"True","whyNot":"Numeric detection is disabled by default, so \"1.0\" is not turned into a float; it becomes text with a keyword sub-field."},{"id":"b","text":"False","why":"Numeric detection is off by default. Without it, the string is mapped as text with a keyword sub-field, not as a float."}],"answer":"b","explanation":"Numeric detection is disabled by default; without it, a string such as \"1.0\" is mapped as text with a keyword sub-field.","concept":"Numeric detection is disabled by default; without it, a string such as \"1.0\" is mapped as text with a keyword sub-field.","rev":1,"updatedAt":"2026-10-26","kind":"scenario","takeaways":["Dynamic mapping guesses types from values; set detection rules and explicit mappings for production data."]},{"id":"elasticsearchbeginner-003","courseId":"elasticsearch-beginner","domain":"data-modeling","topic":"Text fields","prompt":"Shoppers need to find a product when they type the word waterproof, which appears inside the description \"lightweight waterproof hiking jacket\". Which field type fits?","hint":"Some field types match whole values; others look inside sentences for words.","explain":"Some field types store a value as one exact unit, which suits identifiers and labels. Others break the content into smaller pieces, so a single piece can match inside a longer sentence.","source":"https://www.elastic.co/guide/en/elasticsearch/reference/current/text.html","interaction":{"type":"single"},"options":[{"id":"a","text":"A text field","why":"Text fields are built for full-text search, so one word inside a longer description can match."},{"id":"b","text":"A keyword field","whyNot":"Keyword fields match whole values such as IDs and tags, so one word inside a description won't match."},{"id":"c","text":"A boolean field","whyNot":"Boolean fields hold true or false values, not words from a description."},{"id":"d","text":"A date field","whyNot":"Date fields hold calendar values, so they can't be searched for words inside a description."}],"answer":"a","explanation":"Text fields are for full-text search, where words inside a value can match; the docs advise against keyword fields for full-text search.","concept":"Text fields are for full-text search, where words inside a value can match; the docs advise against keyword fields for full-text search.","rev":1,"updatedAt":"2026-10-26","kind":"scenario","takeaways":["Use text for words inside sentences and keyword for exact values such as IDs, tags and statuses."]},{"id":"elasticsearchbeginner-004","courseId":"elasticsearch-beginner","domain":"data-modeling","topic":"Keyword fields","prompt":"Which TWO kinds of data suit a keyword field best?","hint":"Keyword fields are used for sorting, aggregations, and exact term lookups.","explain":"Each field type is built for a different job. Some keep exact values that you match, group, or sort on, while others suit searching inside long content or running ranges over numbers and times.","source":"https://www.elastic.co/guide/en/elasticsearch/reference/current/keyword.html","interaction":{"type":"multiple","tellCount":true},"options":[{"id":"a","text":"Email addresses","why":"Email addresses are structured values you match exactly, which is what keyword fields are for."},{"id":"b","text":"Order status codes like SHIPPED","why":"Status codes are a fixed set of exact values, used for filtering and grouping."},{"id":"c","text":"Long article bodies you search by words","whyNot":"Long content searched by its words belongs in a text field, not a keyword field."},{"id":"d","text":"Prices you filter with ranges","whyNot":"Numbers used in range queries suit numeric types, which Elasticsearch optimizes for ranges."},{"id":"e","text":"Dates you filter by a time window","whyNot":"Dates belong in a date field, which handles time ranges; a keyword field is for exact matching."},{"id":"f","text":"Free-text customer reviews","whyNot":"Reviews are long, free-form text meant for full-text search, so a text field fits better."}],"answer":"ab","explanation":"Keyword fields hold exact, structured values for sorting, aggregations and term queries; long text belongs in text fields and numbers in range queries in numeric fields.","concept":"Keyword fields hold exact, structured values for sorting, aggregations and term queries; long text belongs in text fields and numbers in range queries in numeric fields.","rev":1,"updatedAt":"2026-10-26","kind":"scenario","takeaways":["Pick keyword for exact, structured values you sort, group, or match on; use text for long content."]},{"id":"elasticsearchbeginner-005","courseId":"elasticsearch-beginner","domain":"data-modeling","topic":"Date fields","prompt":"Dynamic mapping is on with default settings. A new document contains the field create_date with the value \"2015/09/02\". What does Elasticsearch add for create_date?","hint":"Look at the default patterns that dynamic mapping checks new string fields against.","explain":"When a new string arrives, dynamic mapping can test its contents against a list of patterns before choosing a type. The list ships with defaults, and each entry names a format the value may follow.","source":"https://www.elastic.co/guide/en/elasticsearch/reference/current/date.html","interaction":{"type":"single"},"options":[{"id":"a","text":"A date field using yyyy/MM/dd HH:mm:ss Z||yyyy/MM/dd Z","why":"The value matches a default date pattern, so the field becomes a date field with that format."},{"id":"b","text":"A text field with a keyword sub-field","whyNot":"That is the default for strings that match no date or number pattern, but this value matches a date pattern."},{"id":"c","text":"A long field, because the value holds digits","whyNot":"Numeric detection is off by default, so digits in a date string don't make the field numeric."},{"id":"d","text":"A date field using epoch_millis","whyNot":"Epoch formats aren't supported as dynamic date formats, so they are not in the default list."}],"answer":"a","explanation":"With default dynamic_date_formats, a new string matching a date pattern is mapped as a date field using that pattern as its format.","concept":"With default dynamic_date_formats, a new string matching a date pattern is mapped as a date field using that pattern as its format.","rev":1,"updatedAt":"2026-10-26","kind":"scenario","takeaways":["Dynamic mapping can turn date-looking strings into date fields; set dynamic_date_formats for production data."]}]