title: generate date range between min and max dates Athena presto SQL sequence error
body: <p>I'm attempting to generate a series of dates in Presto SQL (Athena) using <code>unnest</code> and <code>sequence</code> something similair to <code>generate_series</code> in postgres.</p>
  <p>my table looks like</p>
  <pre><code>job_name | run_date     
  A        | '2021-08-21'
  A        | '2021-08-25' 
  B        | '2021-08-07' 
  B        | '2021-08-24' 
  
  
  SELECT d.job_name, d.run_date
  FROM (
       VALUES
          ('A', '2021-08-21'), ('A', '2021-08-25'),
          ('B', '2021-08-07'), ('B', '2021-08-24')
           ) d(job_name, run_date)
  </code></pre>
  <hr />
  <p>I'm aiming for an output as follows</p>
  <pre><code>job_name |   run_date
         A | 2021-08-21
         A | 2021-08-22
         A | 2021-08-23
         A | 2021-08-24
         A | 2021-08-25
         B | 2021-08-07
         B | 2021-08-08
         B | 2021-08-09
         B | 2021-08-10
         B | 2021-08-11
         B | 2021-08-12
         B | 2021-08-13
         B | 2021-08-14
         B | 2021-08-15
         B | 2021-08-16
         B | 2021-08-17
         B | 2021-08-18
         B | 2021-08-19
         B | 2021-08-20
         B | 2021-08-21
         B | 2021-08-22
         B | 2021-08-23
         B | 2021-08-24
  </code></pre>
  <hr />
  <p>I've attempted to use the following query to achieve this - however I get an error when trying to unnest my date sequence</p>
  <pre><code>SELECT t.job_name, d.dte
  FROM (SELECT job_name
          ,    min(run_date) as mind
          ,    max(run_date) as maxd
          ,    SEQUENCE(min(run_date), max(run_date)) as date_arr
       FROM job_log_table t
       GROUP BY job_name
    )  jd
  CROSS JOIN
      UNNEST(jd.date_arr) d(dte)
  LEFT JOIN job_log_table t 
      ON t.job_name = jd.job_name
      AND t.latest_date = d.dte;
  </code></pre>
  <p>which yields the following error :</p>
  <pre><code>[HY000][100071] [Simba][AthenaJDBC](100071) An error has been thrown from the AWS Athena client. [ErrorCategory:USER_ERROR, ErrorCode:SYNTAX_ERROR], Detail:SYNTAX_ERROR: line 5:14: Unexpected parameters (date, date) for function sequence. Expected: sequence(bigint, bigint, bigint) , sequence(bigint, bigint) , sequence(timestamp, timestamp, interval day to second) , sequence(timestamp, timestamp, interval year to month)
  </code></pre>
  <p>Is this a limitation of Athena's flavour of Presto SQL or have I made a school boy error somewhere?</p>