title: Get total row count after row insertion?
body: <p>Apologies for the super-newbie question but I'm having a surprisingly difficult time finding out whether what I want to do is possible even though it seems basic. I'd like to insert a row in a database and then get the total row count (not total affect row count). I tried:</p>
  
  <pre><code>INSERT INTO apples (type, number) VALUES ('sour', 3) RETURNING COUNT(*);
  </code></pre>
  
  <p>but this gives an error. I also found and tried the <code>ROW_COUNT()</code> function, like so</p>
  
  <pre><code>INSERT INTO apples (type, number) VALUES ('sour', 3); SELECT ROW_COUNT();
  </code></pre>
  
  <p>but this seems to return an affected row count of some kind. What am I doing wrong and is this possible? Thanks and sorry if I missed an existing post, but all the posts I found were for counting affected rows, whereas I just want a total row count.</p>