0

I have a stored procedure calling another stored procedure. The outer stored procedure got tran while the inner stored procedure has no tran just select statement. Does the table in the inner tran gets locked?

The stored procedure s looks like this:

OUTER_SP

BEGIN TRANSACTION
    BEGIN
        EXEC INNER_SP

        INSERT INTO TABLE A
    END
    COMMIT TRANSACTION

INNER_SP

SELECT FROM TABLE A
marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
  • 1
    Which dbms are you using? (Locking can be done in different ways.) – jarlh Mar 17 '22 at 07:16
  • 1
    Depends on your [transaction isolation level](https://stackoverflow.com/questions/16162357/transaction-isolation-levels-relation-with-locks-on-table) – John Wu Mar 17 '22 at 07:27

0 Answers0