title: Unable to group after left join
body: <p>Here is my query (from a trigger):</p>
  
  <pre><code>UPDATE QuoteItemsGroupFeature
  SET Cost = (QuoteItemsGroup.BaseCost + QuoteItemsGroup.AccumulatedCost + 
      ISNULL(SUM(ParentQuoteItemsGroupFeature.Cost), 0)) * INSERTED.Amount
  FROM QuoteItemsGroupFeature INNER JOIN INSERTED
      ON QuoteItemsGroupFeature.QuoteItemsGroupFeatureId = 
      INSERTED.QuoteItemsGroupFeatureId
  INNER JOIN QuoteItemsGroup ON QuoteItemsGroup.QuoteItemsGroupId = 
      INSERTED.QuoteItemsGroupId
  LEFT OUTER JOIN QuoteItemsGroupFeature ParentQuoteItemsGroupFeature ON 
      ParentQuoteItemsGroupFeature.QuoteItemsGroupFeatureId = 
      INSERTED.ParentQuoteItemsGroupFeatureId
  GROUP BY QuoteItemsGroup.BaseCost, 
      QuoteItemsGroup.AccumulatedCost, 
      INSERTED.Feature, 
      INSERTED.Cost
  </code></pre>
  
  <p>It says: </p>
  
  <pre><code>Msg 156, Level 15, State 1, Line 7
  Incorrect syntax near the keyword 'GROUP'.
  </code></pre>