title: How to reduce subqueries in a SQL View
body: <p>I have a query that has a number of subqueries and it is slowing it down.  Many of the subqueries are the same record but different fields.  I was wondering if there was a way to query that record once rather than four times.</p>
  <p>For example:</p>
  <pre><code>select 
  field1 as (select field1 from people where company = g.company),
  field2 as (select field2 from people where company = g.company),
  field3 as (select field3 from people where company = g.company),
  field4 as (select field4 from people where company = g.company)
  from peopleGroup g
  </code></pre>