title: How to select from HQL
body: <p>I'm new to HQL and have a SQL expression I need converted but am unable to select the SQL statement is:</p>
  
  <pre><code>select SenseDate as Time,SenseValue as Value
  from UserData
  where NetworkID = '23'
  and IODeviceID = '129'
  and SenseDate &gt;=  DateAdd("d",-1, GETDATE())
  and SenseDate&lt;=GETDATE()
  </code></pre>
  
  <p>I can run this part in HQL without problems:</p>
  
  <pre><code>from UserData 
  where NetworkID = '23'
  and IODeviceID = '129'
  and SenseDate &gt;=  DateAdd(d,-1, GETDATE())
  and SenseDate&lt;=GETDATE()
  </code></pre>
  
  <p>However I only want the <code>SenseDate</code> and <code>SenseValue</code> values returned, could someone show me how to select as when I try to add <code>select SenseDate, SenseValue</code> etc. I keep getting errors in Netbeans</p>