title: How to Solve 01810. 00000 - "format code appears twice"
body: <p>I am new to sql.I am trying to get the records between two dates. But i am getting ORA-01810 error</p>
  
  <p>Query:</p>
  
  <pre><code>SELECT txnid as txnid,
         to_date(txn_date,'YYYY-MM-DD HH24:MI:SS') as txn_date, 
         amount as amount 
    FROM transactionsdata ct 
   where ct.txn_date &gt;= TO_TIMESTAMP('2018-07-01 00:00:00','yyyy-MM-dd HH:mm:ss') 
     and ct.txn_date &lt;= TO_TIMESTAMP('2018-07-27 00:00:00','yyyy-MM-dd HH:mm:ss');
  </code></pre>
  
  <p>What is wrong in my code?</p>
  
  <p>This is the my table date format: <code>11-07-18 01:05:17.395000000 PM</code></p>