title: MySQL Query Parsing using java
body: <p>I need to parse a query which a user enters, say in a text box, and then what I need, is that I want to encrypt all the values in query leaving the query keywords. To convert it into an equivalent query that can be performed on an encrypted database.<br>
  Such as,   </p>
  
  <pre><code>select name from employee where salary = 10000 
  </code></pre>
  
  <p>I need an equivalent query as,  </p>
  
  <pre><code>select name_enc from employee_enc where salary_enc = 10000_enc   
  </code></pre>
  
  <p>where <code>name_enc</code>,<code>employee_enc</code>, <code>salary_enc</code> and <code>10000_enc</code> are the encrypted values of <code>name</code>, <code>employee</code>, <code>salary</code> and <code>10000</code>.  I need to do this in java and the the database I'm using is MySQL Server where the table <code>Employee</code> is already encrypted.  </p>
  
  <p>Please provide any necessary help. Thanks in advance.</p>