title: Difference between null composite type and composite type with all null columns
body: <p>Is there any difference between a null value and a row type where all columns are null? Postgres queries appear to be able to tell the difference (displaying null columns rather than a blank) and I want to know if there's anything I should be aware of. e.g.</p>
  
  <pre><code>CREATE TYPE node AS (
     rank integer
   , id integer
  );
  
  CREATE TABLE hierarchy (
     node node
  );
  
  INSERT INTO hierarchy (node) VALUES (null);
  INSERT INTO hierarchy (node) VALUES ((null, null));
  
  SELECT *, node IS NULL AS check_null FROM hierarchy;
  </code></pre>
  
  <blockquote>
  <pre><code> node | check_null
  ------+------------
        | t
   (,)  | t
  </code></pre>
  </blockquote>