SQL Script to check SQL Server cluster Nodes.

  • SQL_Hunt

    SSC-Dedicated

    Points: 33450

    Comments posted to this topic are about the item SQL Script to check SQL Server cluster Nodes.

    Thanks.

  • Ron McCullough

    SSC Guru

    Points: 63877

    Here we go again -- the specified as correct answer is an item to be depreciated in a future release of SQL Server and one possible answer, and the one I was unfortunate to select is currently available in all the SQL Server editions specified by the question and does work. So this question which should be teaching us something does exactly the opposite, it encourages us to use an item to be depreciated and declares the another selection as incorrect, but which is available and does work in the specified editions...

    From the cited reference to justify the answer

    Important

    This Microsoft SQL Server 2000 system function is included for backward compatibility. We recommend that you use sys.dm_os_cluster_nodes (Transact-SQL instead.

    Alas and alack woe is me ......

    And now I have a suggested QOD which is:

    Who is currently responsible for checking the accuracy of submitted QODs and when will they be replaced.

    End of rant

    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]

  • SQLRNNR

    SSC Guru

    Points: 281252

    bitbucket-25253 (3/14/2011)


    Here we go again -- the specified as correct answer is an item to be depreciated in a future release of SQL Server and one possible answer, and the one I was unfortunate to select is currently available in all the SQL Server editions specified by the question and does work. So this question which should be teaching us something does exactly the opposite, it encourages us to use an item to be depreciated and declares the another selection as incorrect, but which is available and does work in the specified editions...

    From the cited reference to justify the answer

    Important

    This Microsoft SQL Server 2000 system function is included for backward compatibility. We recommend that you use sys.dm_os_cluster_nodes (Transact-SQL instead.

    Alas and alack woe is me ......

    And now I have a suggested QOD which is:

    I was bit by the same bug. I chose the more current command that is still available and got it wrong. I tested the query of sys.dm_os_cluster_nodes and verified that it does work.

    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

  • Henrico Bekker

    One Orange Chip

    Points: 27652

    Agree, tested SELECT * FROM sys.dm_os_cluster_nodes

    SELECT * FROM fn_virtualservernodes() on 2k8 R2 and both worked...

    **hits head against wall** Need to read questions.....

    -----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
    This thing is addressing problems that dont exist. Its solution-ism at its worst. We are dumbing down machines that are inherently superior. - Gilfoyle

  • malleswarareddy_m

    SSCertifiable

    Points: 5847

    I also got wrong and choosed DMV

    Malleswarareddy
    I.T.Analyst
    MCITP(70-451)

  • UMG Developer

    SSChampion

    Points: 13482

    I too selected the wrong "correct" answer because I assumed you wouldn't choose to use the deprecated version, when there is a current fully supported version that works on all of the editions that are specified. Especially since the current term instance was used, and not the old "virtual server" term.

  • M&M

    SSC-Insane

    Points: 21699

    Correction must be made regarding the wrong answer that is chosen as the right one.

    Infact I chose the last option and got it right as I was thinking the first one to be wrong.

    I guess the error must have crept in inadvertently, we all learn from it 🙂

    M&M

  • angeloc

    SSC Enthusiast

    Points: 137

    Are you sure it's going to be called SQL 2011?

  • Koen Verbeeck

    SSC Guru

    Points: 258965

    When I run "select * from ::fn_virtualservernodes()", this returns no error but an empty resultset (I don't run any failover cluster, so that is to be expected).

    What is the difference between this statement and the "correct" answer?

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

  • This was removed by the editor as SPAM

  • ma-516002

    Hall of Fame

    Points: 3359

    According to http://msdn.microsoft.com/en-us/library/ms176098.aspx this function is deprecated. And since the question did not mention Sql Server 2000 I would say, the correct answer is the last one which is also mentioned on above page.

  • Duncan Pryde

    SSCertifiable

    Points: 7956

    Koen Verbeeck (3/15/2011)


    When I run "select * from ::fn_virtualservernodes()", this returns no error but an empty resultset (I don't run any failover cluster, so that is to be expected).

    What is the difference between this statement and the "correct" answer?

    Yes, I'm confused by that as well. It's SQL 2000 syntax (see this link) but works fine in later versions too.

  • Bex

    SSCrazy

    Points: 2377

    I took the question to be more about do I know the difference between a function having double colon in front of it or not, and not truly about what syntax I would use to return the information, purely based on the answer options. Not the point of the question I'm sure, but it certainly swayed me to go with option 3 as the answer, but in reality I would use the dmv.

    hor_netuk

  • Chris Houghton

    SSCrazy

    Points: 2497

    Tested select * from ::fn_virtualservernodes() on both 2005 and 2008 clusters and it returned correct results for both.

  • Mighty

    SSCrazy Eights

    Points: 8842

    I would like to know why option 2 is not correct.

    Apparently more options are correct, and looking at the future, this should even be the preferred option.

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

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