Query for a list of instances for which data is available in the selected time interval

Hi,

I have a Cloudwatch data source and I would like to create a template variable which contains all instances for which data is available (given a region, namespace and metric name) in the selected time interval. So let’s say I have an ElasticBeanstalk environment with autoscaling active. Instances will come and go over time. I can then use for example the following dimension query to get a list of all instances for which ApplicationLatencyP50 data is available at any point in time (!) for the corresponding EB environment:

dimension_values($region,AWS/ElasticBeanstalk,ApplicationLatencyP50,InstanceId,{“EnvironmentName”:"$service"})

But let’s say I want to narrow down this list and I only want the list of instances for which data is available in the selected time interval. How could I achieve that? Is that even supported?

Regards,
Tobias