none
How can I view the Locals Window?

    Question

  • Hello -

    I don't seem to have the option of viewing locals or watch windows.  When I click on view -> Other Windows, the only options are Web Browser Find Results 1 and Find Results 2.  If I click on debug -> Windows, the only option is Breakpoints.

    Please suggest!

    Juniormint

    Sunday, July 13, 2014 5:57 PM

Answers

  • Hello,

    If I understand correctly, you want to display the Locals window when using Transact-SQL debugger. You must be in debug mode to display the local window: In the SSMS, click Debug -> start Debugging; To access the Locals window, click Windows on Debug menu , and then click Locals. Please refer to the following screen shot:

    If I have any misunderstanding, please let me know.

    Regards,
    Fanny Liu


    Fanny Liu
    TechNet Community Support

    • Proposed as answer by Visakh16MVP Monday, July 14, 2014 8:11 AM
    • Marked as answer by Juniormint10 Tuesday, July 15, 2014 12:00 AM
    Monday, July 14, 2014 8:10 AM
    Moderator

All replies

  • Hi,

    Please post screenshots


    [Personal Site] [Blog] [Facebook]signature

    Sunday, July 13, 2014 6:09 PM
    Moderator
  • Thanks for your response, Pituach.

    What's the best way to post screen shots?

    Juniormint

    Sunday, July 13, 2014 6:47 PM
  • What's the best way to post screen shots?

    In the web UI, there is a button with some moutains on. You use that button to insert images. You may have to go through some verification procedure first. (I guess you will be told.) In the meanwhile you can use Skydrive, Dropbox or similar service.

    While I'm at it, the question appear to be asked in the wrong forum, since this forum is for T-SQL, and we don't deal with windows in T-SQL.


    Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se
    Sunday, July 13, 2014 9:49 PM
  • Thanks for your response, Erland!

    I am confused by your answer.  I am asking about viewing the locals and watch windows.  Both are integral to debugging in T-SQL.  In Sql Server 2005, I never had a hard time viewing these.  For some reason, in 2008 R2, I am not able to view either.

    Are you sure I'm in the wrong forum?  If so, which forum should I be in?

    Juniormint

    Monday, July 14, 2014 3:42 AM
  • You can find your answer in hear: http://msdn.microsoft.com/en-us/library/aa238778(v=vs.60).aspx
    Monday, July 14, 2014 3:47 AM
  • Which client tool are you using? Are you talking about seeing locals window on SQL Server Management Studio (SSMS) ? Or is the question on seeing the windows on Business Intelligence Development Stuido (BIDS / SQL Server Data Tools for BI (SSDT-BI) which is where you create SSIS packages.

    In BIDS/SSDT you can view them as below

    http://datachix.com/2010/12/28/debugging-ssis-variables-part-two/


    Please Mark This As Answer if it helps to solve the issue Visakh ---------------------------- http://visakhm.blogspot.com/ https://www.facebook.com/VmBlogs

    Monday, July 14, 2014 4:48 AM
  • Look at here. 

    http://blog.sqltechie.com/2011/07/debug-query-in-ssms.html

    Amish shah

    Monday, July 14, 2014 6:35 AM
  • Hello,

    If I understand correctly, you want to display the Locals window when using Transact-SQL debugger. You must be in debug mode to display the local window: In the SSMS, click Debug -> start Debugging; To access the Locals window, click Windows on Debug menu , and then click Locals. Please refer to the following screen shot:

    If I have any misunderstanding, please let me know.

    Regards,
    Fanny Liu


    Fanny Liu
    TechNet Community Support

    • Proposed as answer by Visakh16MVP Monday, July 14, 2014 8:11 AM
    • Marked as answer by Juniormint10 Tuesday, July 15, 2014 12:00 AM
    Monday, July 14, 2014 8:10 AM
    Moderator
  • I am confused by your answer.  I am asking about viewing the locals and watch windows.  Both are integral to debugging in T-SQL.  

    But they are not T-SQL. (And I disagree with "integral". The only thing I use for debugging T-SQL is SELECT and PRINT. Too much hassle to get T-SQL debugger to work.)

    In Sql Server 2005, I never had a hard time viewing these.  

    SSMS 2005 did not even have T-SQL debugger, had it?

    Are you sure I'm in the wrong forum?  If so, which forum should I be in?

    It would be the Tools forum. At least if you are using SQL Server Management Studio. But it is not fully clear that you do.


    Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se
    Monday, July 14, 2014 9:56 AM
  • Thank all of you!  I did not realize that you could only get the menu that displays the Locals window when you clicked Debug.  What a drag!  That means before I can set them, I have to actually start Debug and have to put a breakpoint right at the beginning, just to get the menu to display!!!! Clunky!

    Juniorming

    Tuesday, July 15, 2014 12:02 AM