• You need to get rid of the massive GROUP BY; you should be able to do the SUM() in a subquery rather than the main query, but I can't be sure which columns come from which views/tables so I can't rewrite any part of the query now.

    Until then, at least GROUP BY the ORDER BY columns first, to reduce the sorting required to satisfy the query, viz:

    GROUP BY fldConsulNo, fldCCGroupCd, fldCCSortOrder,

    RC.fldCCCd, fldSubCCNo,

    fldCCGroupDesc,

    fldConsulName,

    tblConsul.fldConsulKey,

    fldCCDesc, fldSubCCName, v.fldCostCenterKey

    ORDER BY fldConsulNo, fldCCGroupCd, fldCCSortOrder, fldCCCd , fldSubCCNo

    SQL DBA,SQL Server MVP(07, 08, 09) A socialist is someone who will give you the shirt off *someone else's* back.