title: Why Cassandra cql query with hexadecimal literal works but textAsBinary does not?
body: <p>I can do cassandra cql queries using hexadecimal literal, but when I try to use textAsBlob it does not work</p>
  
  <p>For example the following works just fine:</p>
  
  <pre><code>cqlsh:sprich&gt; SELECT * FROM "STOCK_CHECK_RTAM_ITEM_INDEX" WHERE key in (0x3631313230);
  
   key          | column1        | value
  
  --------------+----------------+------------------------------------
  
  0x3631313230 | 0x000330303100 | 0xf77374b5eced11e3a877005056b37d30
  
   0x3631313230 | 0x000330303200 | 0xf7757084eced11e3a877005056b37d30
  
   0x3631313230 | 0x000330303400 | 0xf7712ac8eced11e3a877005056b37d30
  </code></pre>
  
  <p>But the following two queries do not:</p>
  
  <pre><code>cqlsh:sprich&gt; SELECT * FROM "STOCK_CHECK_RTAM_ITEM_INDEX" WHERE key in (textAsBlob("0x3631313230"));
  
  Bad Request: line 1:84 missing EOF at ')'
  text could not be lexed at line 1, char 15
  
  cqlsh:sprich&gt; SELECT * FROM "STOCK_CHECK_RTAM_ITEM_INDEX" WHERE key in (textAsBlob("3631313230"));
  Bad Request: line 1:82 missing EOF at ')'
  text could not be lexed at line 1, char 15
  </code></pre>
  
  <p>The following two queries do not give a syntax error but do not return the proper results as well:</p>
  
  <pre><code>cqlsh:sprich&gt; SELECT * FROM "STOCK_CHECK_RTAM_ITEM_INDEX" WHERE key in (textAsBlob('0x3631313230'));
  
  cqlsh:sprich&gt; SELECT * FROM "STOCK_CHECK_RTAM_ITEM_INDEX" WHERE key in (textAsBlob('3631313230'));
  </code></pre>
  
  <p>Why is textAsBlob is not working? What mistake am I making in the proper use of textAsBlob?</p>