Is there a limit to size in KB's for query parsing?

  • Hi All,

    I'm working with a SELECT statement that is pushing some 1000+ columns with some column names as long as 50 characters in the result set.

    Here's an example of the query:

    SUM(case when zip_ZIP_OwnerOccupiedHousingUnitsByValue80000To99999 < 0 and zip_ZIP_OwnerOccupiedHousingUnitsByValue80000To99999 <> -1 then 1 else 0 end) as zip_ZIP_OwnerOccupiedHousingUnitsByValue80000To99999_BucketError,

    SUM(case when zip_ZIP_OwnerOccupiedHousingUnitsByValue80000To99999 >= 0 AND zip_ZIP_OwnerOccupiedHousingUnitsByValue80000To99999 < 8 then 1 else 0 end) as zip_ZIP_OwnerOccupiedHousingUnitsByValue80000To99999_Bucket0,

    What's happening is the developers are complaining about the execution time on this particular SELECT statement, and when I try to use the estimated query plan, SSMS pukes and throws an error message at me.

    Is there a size limit in KB's for what the query optimizer can handle?

    😀

  • Another note. I did not write this query, I'm just responsible for it when it runs like crap.

    😀

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply