title: How to remove lockTable after trigger?
body: <p>I have a trigger:</p>
  <pre><code>Create trigger Update_applicationUpdate_MainTable 
  on MainTable 
  after update 
  as
      Update [SubTable] with(ROWLOCK) 
      set [LatUpdateTime] = SYSDATETIME() 
      where [dbo].[SubTable].[ClientTableId] in (select Id from inserted) 
        and [Table] = '[dbo].[MainTable]';
  </code></pre>
  <p>After the start of the transaction:</p>
  <pre><code>update [dbo].[MainTable]
  set [Name] = 'Test1' 
  where id = 1
  </code></pre>
  <p>Locking the <code>MainTable</code> and <code>SubTable</code> for another transaction.</p>
  <p>How to block only a row?</p>
  <p>My second transaction, but it falls pending because the trigger is locking the table:</p>
  <pre><code>update [dbo].[MainTable]
  set [Name] = 'Test1' 
  where id = 2
  </code></pre>
  <p>I'm using only SQL Server</p>