title: How to rename a table in SQL Server?
body: <p>The <code>SQL</code> query that I have used is :</p>
  
  <pre><code>ALTER TABLE oldtable RENAME TO newtable;
  </code></pre>
  
  <p>But, it gives me an error.</p>
  
  <blockquote>
    <p>Server: Msg 156, Level 15, State 1, Line 1<br>
    Incorrect syntax near the keyword 'TO'.</p>
  </blockquote>