title: Converting a query to parameterized prepared statements in java jdbc template
body: <p>How can I convert a normal query to parameterized prepared statement in spring JDBC? Following is the piece of query I am trying to change:</p>
  
  <pre><code>private String queryBuilder(Request request, Map&lt;String, String&gt; action) {
      StringBuilder builder = new StringBuilder();
      builder.append("select * " +
                     "from google_play " +
                     "where ID = '" + request.getId() + "' and " +
                     "SYS_CD = '" + request.getSystemCd() + "' and " +
                     "SYS_DT &gt;='"+request.getSystemDate+"'");
      return builder.toString();
  }
  </code></pre>
  
  <p>Can someone suggest a proper way to change this query to avoid sql injection? I have googled a solution for this but couldn't find an exact one.</p>