I am very new to elasticsearch and I was wondering if there is any way to build a range query in java when I am only given strings (more specifically I am given IP addresses as strings)? The strings will look like this "IP_ADDRESS1 TO IP_ADDRESS2"
. As far as I can see it does not seem to be possible. In the elastic docu it says that ip addresses always have to be provided as datatype ip
in order to execute a range query. However, I am not able/ allowed to change the type of the ip addresses from string to ip. Does somebody maybe know a workaround for that?
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…