Prepare your data
Define the field names and field types for your application schema. Each field's value is a sample that represents the intended field type.
{
"table_name": {
"int": 1,
"int_array": [
1,
2,
3,
4
],
"float": 12.5,
"float_array": [
12.1,
12.2,
12.3
],
"double": 12.6,
"double_array": [
12.1,
12.2,
12.3
],
"literal": "LITERAL type",
"literal_array": [
"OpenSearch",
"Open",
"Search"
],
"short_text": "SHORT_TEXT type",
"text": "TEXT type",
"timestamp": 1624502392077,
"geo_point": "12 15"
}
}
Upload the file
Select Use File and upload the file you prepared:

Adjust field types
When OpenSearch automatically maps field types, double and double_array are mapped to float and float_array respectively, short_text, text, and geo_point are mapped to literal, and timestamp is mapped to int.
This automatic mapping can be inaccurate because the sample values for some field types are ambiguous. After uploading the file, you may need to adjust these field types.
该文章对您有帮助吗?