elasticsearch jdbc type mapping -
i'm trying populate elasticsearch index starting mysql query. working on windows , batch this:
echo {^ "type" : "jdbc",^ "jdbc" : {^ "url" : "jdbc:mysql://localhost:3306/ade_ver",^ "user" : "...",^ "password" : "...",^ "sql" : select ... ",^ "index" : "ade_ver",^ "type" : "my_type",^ "type_mapping": "{\"my_type\":{\"properties\":{\"prop1\":{\"type\":\"string\"},\"prop2\":{\"type\":\"string\"},**\"prop3\":{\"type\":\"string\",\"index\":\"not_analyzed\"}**, ecc.. }}}",^ "elasticsearch" : {^ "cluster" : "elasticsearch",^ "host" : "localhost",^ "port" : 9300^ }^ }^ } | "%java_home%\bin\java" ecc..
now, works fine, index populated expected data. problem every field set "analyzed", if i'm trying set of them not analyzed. wrong?
i solved issue creating index , mapping beforehand, , used elasticsearch-jdbc import data mysql
Comments
Post a Comment