title: Postgres: Could not identify an ordering operator for type unknown
body: <p>I have this query with prepared statement:</p>
  
  <pre><code>SELECT * FROM ONLY service_services
  UNION ALL
  SELECT * FROM fleet.service_services
  WHERE deleted=false
  ORDER BY $1
  LIMIT $2
  </code></pre>
  
  <p>I send the value of <code>name ASC</code> to <code>$1</code> and <code>10</code> to <code>$2</code></p>
  
  <p>For some reason I am getting this error:</p>
  
  <pre><code>could not identify an ordering operator for type unknown
  </code></pre>
  
  <p>If I hard code the <code>name ASC</code> instead of $1, like this:</p>
  
  <pre><code>SELECT * FROM ONLY service_services
  UNION ALL
  SELECT * FROM fleet.service_services
  WHERE deleted=false
  ORDER BY name ASC
  LIMIT $1
  </code></pre>
  
  <p>It is working fine.</p>
  
  <p>What am I doing wrong?</p>