I have table on Elassandra. I need to create elastic search index on only few columns of that table not on entire table.
{"discover":".*"} option is creating index on all columns of the table. But i am unable create index on few columns.
curl -XPUT -H 'Content-Type: application/json' 'http://localhost:9200/test_idx' -d '{
"settings": {"keyspace":"dm" },
"mappings": {
"mytable": {
"properties": {
"did": { "type": "text" },
"defectx": { "type": "float" },
"defecty": { "type": "float" },
"mdc": { "type": "text" }
}
}
}
}'
Not sure what is the mistake. Please help me to correct syntax for few columns but not all.