title: Select list of dates from given range in Firebird
body: <p>I'm designing a report that returns PurchaseOrder due in future week.</p>
  
  <p>Query that I've added below returns <code>PurchaseOrder</code> due for a particular <code>Commodity</code>, <code>AmountDue</code> and its <code>DeliveryDate</code>.</p>
  
  <p>Obviously it only returns PO_Dates that are in the table. What I want is to also include dates where no PO is expected, i.e. null for those cell.</p>
  
  <p>To me one possibility is to LEFT JOIN the dataset with set of dates of future week on Date column, that will eventually make the result null where no Purchase Order is expected.</p>
  
  <p>In Firebird I don't know how to select list of week long dates and then use it in the join.</p>
  
  <pre><code>SELECT
      PURCHASE_ORDER_DET.COMMODITYID AS COM_ID,
      PURCHASE_ORDER_DET.DELIVERYDATE + CAST ('29.12.1899' AS DATE) as DLV_DATE,
      SUM(PURCHASE_ORDER_DET.REQQUANTITY) as DLV_DUE
  FROM
      PURCHASE_ORDER_DET
  LEFT JOIN PURCHASE_ORDER_HDR on PURCHASE_ORDER_HDR.POH_ID = 
  PURCHASE_ORDER_DET.POH_ID
  WHERE 
      PURCHASE_ORDER_DET.COMMODITYID = 1
      AND PURCHASE_ORDER_HDR.STATUS in (0,1,2)
      AND PURCHASE_ORDER_DET.DELIVERYDATE + CAST ('30.12.1899' AS TIMESTAMP) &gt;= '3.01.2019'
      AND PURCHASE_ORDER_DET.DELIVERYDATE + CAST ('30.12.1899' AS TIMESTAMP) &lt;= '9.01.2019'
      AND PURCHASE_ORDER_DET.DELETED is NULL
  Group by 
      PURCHASE_ORDER_DET.COMMODITYID,
      PURCHASE_ORDER_DET.DELIVERYDATE
  </code></pre>
  
  <p><strong>DataSet</strong></p>
  
  <pre><code>COM_ID    DLV_DATE       DLV_DUE    
  1         3.01.2019     50.000000
  1         5.01.2019     10.000000
  </code></pre>
  
  <p><strong>Expected</strong></p>
  
  <pre><code>COM_ID    DLV_DATE       DLV_DUE    
  1         3.01.2019     50.000000
  1         4.01.2019     null
  1         5.01.2019     10.000000
  1         6.01.2019     null
  1         7.01.2019     null
  1         8.01.2019     null
  1         9.01.2019     null
  </code></pre>