title: Cannot create a table due to naming conflict
body: <p>I am trying to create a table in my database and it gives me the following error.</p>
  
  <blockquote>
  <pre><code>ERROR:  type "tbl_last_alert" already exists
  HINT:  A relation has an associated type of the same name, so you must use a name that doesn't conflict with any existing type.
  </code></pre>
  </blockquote>
  
  <p>Then I thought that the table must exist so I ran the following query:</p>
  
  <pre><code>select * from pg_tables;
  </code></pre>
  
  <p>But could not find anything. Then I tried:</p>
  
  <blockquote>
  <pre><code>select * from tbl_last_alert;
  ERROR:  relation "tbl_last_alert" does not exist
  </code></pre>
  </blockquote>
  
  <p>Any idea how to sort this?</p>
  
  <p>i am tying to rename the type by </p>
  
  <pre><code>ALTER TYPE v4report.tbl_last_alert RENAME TO tbl_last_alert_old;
  ERROR:  v4report.tbl_last_alert is a table's row type
  HINT:  Use ALTER TABLE instead.
  </code></pre>
  
  <p>and getting the error.</p>