View 7

  • Comments posted to this topic are about the item View 7

    If everything seems to be going well, you have obviously overlooked something.

    Ron

    Please help us, help you -before posting a question please read[/url]
    Before posting a performance problem please read[/url]

  • I picked no because of the COUNT_BIG requirement, but also because it is not known if ANSI_NULLS and QUOTED_IDENTIFIER were ON when the table was created. (and ANSI_NULLS when the view was created)

    Need an answer? No, you need a question
    My blog at https://sqlkover.com.
    MCSE Business Intelligence - Microsoft Data Platform MVP

  • Wow, did a google search and there was no mention in any of the four posts I checked about the count_big so I got it wrong. Nice Q and nice reference article.

  • I have created numerous indexed views and answered numerous questions about them here on ssc as well, made this an easy question. Thanks!

  • Nice one, thank you

    Iulian

  • dogramone (5/8/2012)


    Wow, did a google search and there was no mention in any of the four posts I checked about the count_big so I got it wrong.

    You would have found it if you checked Books Online: http://msdn.microsoft.com/en-us/library/ms191432.aspx. We all like to bash BOL when we find something missing or a documentation error, but in reality I still think SQL Server is one of the best documented programs on the market.

    EDIT: Forgot to add: Nice question, but the code was a bit hard to read. May I suggest that the next time someone uses a screenshot for the question instead of just providing the code, he or she first increases the font size?


    Hugo Kornelis, SQL Server/Data Platform MVP (2006-2016)
    Visit my SQL Server blog: https://sqlserverfast.com/blog/
    SQL Server Execution Plan Reference: https://sqlserverfast.com/epr/

  • This was removed by the editor as SPAM

  • Interesting count & count_big. Learned something today. Thanks.

  • Hugo Kornelis (5/8/2012)


    dogramone (5/8/2012)


    Wow, did a google search and there was no mention in any of the four posts I checked about the count_big so I got it wrong.

    You would have found it if you checked Books Online: http://msdn.microsoft.com/en-us/library/ms191432.aspx. We all like to bash BOL when we find something missing or a documentation error, but in reality I still think SQL Server is one of the best documented programs on the market.

    Agreed. AND BOL does have space for comments, so if it IS incorrect, we have the ability to fix it, rather than just complaining.

    EDIT: Forgot to add: Nice question, but the code was a bit hard to read. May I suggest that the next time someone uses a screenshot for the question instead of just providing the code, he or she first increases the font size?

    Agreed. They could also either 1) use PNG instead of JPG, or 2) increase the JPG quality setting of their screenshot app so there's not so much lossy compression.

    The question itself was quite good, and the link provided in the explanation really does provide a good explanation of why this happens. (Essentially, SQL Server requires COUNT_BIG() on indexed views to prevent a potential overflow for tables with large numbers of rows.)

    I got the question right because the existence of the question implied there was an issue, learned about the issue, and got a chance to comment! Win-win-win!

  • Good question and explanation.

  • Good Question Ron.

    Jason...AKA CirqueDeSQLeil
    _______________________________________________
    I have given a name to my pain...MCM SQL Server, MVP
    SQL RNNR
    Posting Performance Based Questions - Gail Shaw[/url]
    Learn Extended Events

  • Nice question, thanks!

  • Hugo Kornelis (5/8/2012)


    dogramone (5/8/2012)


    Wow, did a google search and there was no mention in any of the four posts I checked about the count_big so I got it wrong.

    You would have found it if you checked Books Online: http://msdn.microsoft.com/en-us/library/ms191432.aspx. We all like to bash BOL when we find something missing or a documentation error, but in reality I still think SQL Server is one of the best documented programs on the market.

    EDIT: Forgot to add: Nice question, but the code was a bit hard to read. May I suggest that the next time someone uses a screenshot for the question instead of just providing the code, he or she first increases the font size?

    Ran and ran again to check using IE 7 Windows XP on a 17 inch monitor, zoom set to 100%, my vision with glasses on, checked just last week at 20/20 and I have NO problem reading the question what so ever.

    Any suggestions so that I can satisfy those who have stated that it was / is difficult to read ?

    If everything seems to be going well, you have obviously overlooked something.

    Ron

    Please help us, help you -before posting a question please read[/url]
    Before posting a performance problem please read[/url]

  • bitbucket-25253 (5/8/2012)


    Hugo Kornelis (5/8/2012)


    dogramone (5/8/2012)


    Wow, did a google search and there was no mention in any of the four posts I checked about the count_big so I got it wrong.

    You would have found it if you checked Books Online: http://msdn.microsoft.com/en-us/library/ms191432.aspx. We all like to bash BOL when we find something missing or a documentation error, but in reality I still think SQL Server is one of the best documented programs on the market.

    EDIT: Forgot to add: Nice question, but the code was a bit hard to read. May I suggest that the next time someone uses a screenshot for the question instead of just providing the code, he or she first increases the font size?

    Ran and ran again to check using IE 7 Windows XP on a 17 inch monitor, zoom set to 100%, my vision with glasses on, checked just last week at 20/20 and I have NO problem reading the question what so ever.

    Any suggestions so that I can satisfy those who have stated that it was / is difficult to read ?

    I also have no problem reading it and I am old. So there must be some variance in the way it renders.

  • Cliff Jones (5/8/2012)


    bitbucket-25253 (5/8/2012)


    Hugo Kornelis (5/8/2012)


    dogramone (5/8/2012)


    Wow, did a google search and there was no mention in any of the four posts I checked about the count_big so I got it wrong.

    You would have found it if you checked Books Online: http://msdn.microsoft.com/en-us/library/ms191432.aspx. We all like to bash BOL when we find something missing or a documentation error, but in reality I still think SQL Server is one of the best documented programs on the market.

    EDIT: Forgot to add: Nice question, but the code was a bit hard to read. May I suggest that the next time someone uses a screenshot for the question instead of just providing the code, he or she first increases the font size?

    Ran and ran again to check using IE 7 Windows XP on a 17 inch monitor, zoom set to 100%, my vision with glasses on, checked just last week at 20/20 and I have NO problem reading the question what so ever.

    Any suggestions so that I can satisfy those who have stated that it was / is difficult to read ?

    I also have no problem reading it and I am old. So there must be some variance in the way it renders.

    Your old ... nah .. your just a young whipper snapper, now I am old, to know how old trying running this

    SELECT DATEDIFF ( yy , '04/18/1932', GETDATE() ) or look at my profile. Now some who know me say that I am 3 days older than dirt, and on some days I do feel that way.

    If everything seems to be going well, you have obviously overlooked something.

    Ron

    Please help us, help you -before posting a question please read[/url]
    Before posting a performance problem please read[/url]

Viewing 15 posts - 1 through 15 (of 31 total)

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