Scenario
Right now you can only index 1 field into 1 OpenSearch field. I'd like to be able to index the same field into two separate OpenSearch fields for use within ElasticGraph. This unlocks the ability to create keywords for precise search as well as text fields for partial searching.
t.field "customerName", "String" do |f|
f.mapping type: "keyword"
f.additional_mapped_field "customerNameText", type: "text" #new code
end
Possible solution
Example of what this could look like within the schema:
t.field "customerName", "String" do |f|
f.mapping type: "keyword"
f.additional_mapped_field "customerNameText", type: "text" #new code
end
In this case customerName and customerNameText both get indexed as their own fields within OpenSearch that you can perform all relevant ElasticGraph operations to that type on.
Open questions
- Can this be added without a re-index? Assume not
Scenario
Right now you can only index 1 field into 1 OpenSearch field. I'd like to be able to index the same field into two separate OpenSearch fields for use within ElasticGraph. This unlocks the ability to create keywords for precise search as well as text fields for partial searching.
Possible solution
Example of what this could look like within the schema:
In this case
customerNameandcustomerNameTextboth get indexed as their own fields within OpenSearch that you can perform all relevant ElasticGraph operations to that type on.Open questions