title: How to use another table fields as a criteria for MS Access
body: <p>This is the <code>MS Access</code> related query. </p>
  
  <p>I have a table with three columns: <code>FName, FValue and VDate</code> in MS Access.(The actual table is quite big but the following example is for reference.)
  !<a href="http://postimg.org/image/bx0grwoa3/" rel="nofollow">http://postimg.org/image/bx0grwoa3/</a></p>
  
  <p>Now I want to get a following kind of query output: Get the minimum quarterly values for each unique name. For example:
  !<a href="http://postimg.org/image/je1w7gdi1/" rel="nofollow">http://postimg.org/image/je1w7gdi1/</a></p>
  
  <p>So far I am able to get the output for one quarter by hardcoded criteria, by using the following (In MS Access)</p>
  
  <p>SQL string is: </p>
  
  <pre><code>SELECT Table.FName, Min(Table.FValue) AS MinOfFValue, First(Table.VDate) AS FirstOfVDate
  FROM [Table] LEFT JOIN [Table] AS Table_1 ON Table.FValue = Table_1.FValue
  WHERE (((Table.VDate)&gt;#3/31/2014# And (Table.VDate)&lt;#7/1/2014#))
  GROUP BY Table.FName;
  </code></pre>
  
  <p>Now instead of the putting date hard coded, I want the dates to be part of a table where Quarter name, from date and to dates are there and Access takes them one by one and give the desired output.</p>
  
  <p>Thanks in advance.</p>