# Plotting Weather Forecast Data

**URL:** <https://community.influxdata.com/t/plotting-weather-forecast-data/9135>\
**Category:** Dashboards\
**Tags:** grafana, time, query\
**Created:** [March 23, 2019, 3:30pm UTC](https://community.influxdata.com/t/plotting-weather-forecast-data/9135 "2019-03-23T15:30:31Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![me2017](https://avatars.discourse-cdn.com/v4/letter/m/bcef8e/32.png) [@me2017](https://community.influxdata.com/u/me2017)\
**Post date:** [March 23, 2019, 3:30pm UTC](https://community.influxdata.com/t/plotting-weather-forecast-data/9135/1 "2019-03-23T15:30:32Z")

</div>

I’m writing weather forecast data to InfluxDB. For each write point there will be three timestamps:

1. Time of collection
2. Time which data point occurs (in future)
3. Time of forecast issue

My question is: how can I create a query that uses **2) Time which data point occurs (in future)**, rather than **1) Time of collection**?

And as a larger question: Is there a better, or more correct way of structuring my write points (see below)?

My current query:

`> SELECT "temperatureHigh" FROM "darksky_daily" WHERE $timeFilter`

To illustrate, my graph in Grafana currently looks like this:

 ![ds_graph](https://us1.discourse-cdn.com/flex023/uploads/influxdata/original/2X/7/76c7f4f57c043c4fb72a4e856bfc6ccd1901b740.png)

Some additional details…

This is how I’m writing points to InfluxDB. Each point is tagged as daily\_n where n is typically 1-8:

```
{'fields': {'ReportTime': 1553929200, 'temperatureLow': 46.04, 'temperatureLowTime': 1554040800,
 'temperatureHigh': 68.82, 'temperatureHighTime': 1553983200, ...}, 'time': '2019-03-23T14:59:03Z',
 'tags': {'location': 'San Pablito', 'daily': 'daily_8'}, 'measurement': 'darksky_daily'}

```

The results in InfluxDB:

```
> select temperatureLow,temperatureLowTime,temperatureHigh,temperatureHighTime from "darksky_daily" order by time desc limit 20
name: darksky_daily
time temperatureLow temperatureLowTime temperatureHigh temperatureHighTime
---- -------------- ------------------ --------------- -------------------
2019-03-23T15:00:03Z 46.04 1554040800 68.82 1553983200
2019-03-23T15:00:03Z 37.94 1553436000 60.06 1553378400
2019-03-23T15:00:03Z 43.23 1553954400 64.42 1553896800
2019-03-23T15:00:03Z 44.18 1553781600 53.68 1553727600
2019-03-23T15:00:03Z 47.76 1553695200 56.48 1553641200
2019-03-23T15:00:03Z 41.36 1553868000 60.47 1553810400
2019-03-23T15:00:03Z 45.12 1553608800 57.45 1553554800
2019-03-23T15:00:03Z 48.05 1553497200 62.9 1553468400
-------------------------------------------------------------
2019-03-23T14:30:02Z 45.12 1553608800 57.45 1553554800
2019-03-23T14:30:02Z 48.05 1553497200 62.9 1553468400
2019-03-23T14:30:02Z 43.23 1553954400 64.42 1553896800
2019-03-23T14:30:02Z 46.04 1554040800 68.82 1553983200
2019-03-23T14:30:02Z 37.94 1553436000 60.04 1553378400
2019-03-23T14:30:02Z 41.36 1553868000 60.47 1553810400
2019-03-23T14:30:02Z 44.18 1553781600 53.68 1553727600
2019-03-23T14:30:02Z 47.76 1553695200 56.48 1553641200
```
