I have longitude and latitude field from postgres into elasticsearch using jdbc-river. Is there any way to plot longitude and latitude in kibana? I tried to convert to geo_point but I see that it only takes geo_hash.
It uses a geohash aggregation on geo_point.
So if your mapping is correct, it should work
Here is my mapping:
PUT /_river/fault/_meta
{
"type" : "jdbc",
"jdbc" : {
"url" : "jdbc:postgresql://localhost:5432/gis",
"user" : "test",
"password" : "test",
"sql" : [
{
"statement" : "select latitude as \"location.lat\",longitude \"location.lon\",zone from alarms"
}
],
"index" : "fault",
"type" : "alert_status",
"schedule": "0 0/1 * * * ?"
},
"type_mapping" : {
"alert_status" : {
"properties" : {
"location" : {
"type" : "geo_point",
"lat_lon" : true
}
}
}
}
}
I had posted issue about creating geo_point here.