title: SQL server trimming string
body: <p>I have a query, I want to Trim a column and get the only Right side values:</p>
  
  <p><a href="https://i.stack.imgur.com/D2Epl.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/D2Epl.png" alt="enter image description here"></a></p>
  
  <p>Here in the pic the result is like <code>SubAccountCode</code> and <code>SubaccountName</code> but user has entered code and name in <code>SubaccountName</code>. I want to trim the codes from <code>Subaccountname</code> and update the table. T</p>
  
  <p>The query I have tried is mentioned below, but I think it's not so working:</p>
  
  <pre><code> Select Substring(Subaccountname,8,20)as Name from #temp
  </code></pre>