In T-SQL debugging, "Step Into" behaves like "Step Over."

Jungsooooo 0 Reputation points
2024-11-22T11:14:07.62+00:00
  • visual studio 2022 (17.11.5)
  • Microsoft SQL Server 2022 (RTM) - 16.0.1000.6 (X64) Oct 8 2022 05:58:25 Copyright (C) 2022 Microsoft Corporation Developer Edition (64-bit) on Windows 10 Enterprise 10.0 <X64> (Build 22631: ) (Hypervisor)

During the debugging process of a procedure, when using Step Into on the EXEC procedure statement, it behaves like Step Over. However, the results (e.g., return_value) are displayed correctly.

What could be the reason for this behavior, and how can it be resolved?

User's image

On the 6th line, when I use Step Into (F11), [usp_user_insert] does not open, and it skips directly to:

SELECT @return_value as 'Return Value'.

SQL Server | Other
{count} votes

1 answer

Sort by: Most helpful
  1. LiHongMSFT-4306 31,566 Reputation points
    2024-11-25T02:51:57.8666667+00:00

    Hi @Jungsooooo

    To debug Stored Procedure, please follow the steps here: Debug stored procedures.

    Best regards,

    Cosmog


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.