title: How to list null datetimes records from temperature records table
body: <p>I have a temperature table like this</p>
  
  <pre><code>|d_id   |d_l_id |d_temperature |d_humidity |d_log_date          |
  |1      |1      |29.80         |23.40      |2020-02-29 00:00:01 |
  |2      |1      |29.80         |23.40      |2020-02-29 00:00:02 |
  |3      |1      |30.00         |23.90      |2020-02-29 00:00:03 |
  |4      |1      |30.00         |23.90      |2020-02-29 00:00:04 |
  |5      |1      |30.00         |23.90      |2020-02-29 00:00:05 |
  |6      |1      |30.00         |23.90      |2020-02-29 00:00:06 |
  |7      |1      |29.80         |23.40      |2020-02-29 00:30:51 |
  |8      |1      |30.00         |23.90      |2020-02-29 00:30:52 |
  |9      |1      |30.00         |23.90      |2020-02-29 00:30:53 |
  |10     |1      |29.70         |23.40      |2020-02-29 00:30:54 |
  </code></pre>
  
  <p>and I'm avg with this sql</p>
  
  <pre><code>SELECT count(*) rec_count, avg(d_temperature) avg_temp, avg(d_humidity) avg_hum, d_log_date FROM its.data
  where d_l_id = 1
  GROUP BY (UNIX_TIMESTAMP(d_log_date)) DIV 30;
  </code></pre>
  
  <p>and getting this result</p>
  
  <pre><code>|6  |30.645455 |27.381818 |2020-02-29 00:00:01|
  |4  |30.579311 |27.306896 |2020-02-29 00:01:51|
  </code></pre>
  
  <p>Sometimes device lost connection and device is not recording.
  But I need to list like this.
  How can I do that.</p>
  
  <pre><code>|6  |30.645455 |27.381818 |2020-02-29 00:00:01|
  |0  |null or 0 |null or 0 |2020-02-29 00:00:30|   &lt;&lt;
  |0  |null or 0 |null or 0 |2020-02-29 00:01:00|   &lt;&lt;
  |0  |null or 0 |null or 0 |2020-02-29 00:01:30|   &lt;&lt;
  |0  |null or 0 |null or 0 |2020-02-29 00:02:00|   &lt;&lt;
   .   .          .          .                      &lt;&lt;
   .   .          .          .                      &lt;&lt;
  |0  |null or 0 |null or 0 |2020-02-29 00:29:00|   &lt;&lt;
  |0  |null or 0 |null or 0 |2020-02-29 00:29:30|   &lt;&lt;
  |0  |null or 0 |null or 0 |2020-02-29 00:30:00|   &lt;&lt;
  |0  |null or 0 |null or 0 |2020-02-29 00:30:30|   &lt;&lt;
  |4  |30.579311 |27.306896 |2020-02-29 00:30:51|
  </code></pre>