Querry Influx IP Adress filter third octet

Hi everybody,
i like to do a variable witch filters the result by IP Adress but only in the thrid octet.
For Example the Querry give back:

Than i like to have a Variable that contains for Example ..2.* so i get the result from all IPs matching this pattern. is this posible?
Thanks in Advanced

Are you using flux or influxql? maybe leverage the filter by regex? not my forte

or another approach drop downs

Hi i´m useing InfluxDB not Flux

Influxdb is a time series database. You can query the data 2 ways


Which one are you using and could you show us how you are doing it?

i think i use Influxql