title: DB2 Error SQLCODE=-103, SQLSTATE=42604
body: <p>I am trying to update a table, but it isn't working and giving this sql error.</p>
  
  <pre><code>//Updating Buy Table
  Integer stkbid = Integer.parseInt(request.getParameter("stockBid"));
  System.out.println("stock buy id : " + stkbid);
  //get buy details
  PreparedStatement stmtbuy = conn.prepareStatement(
          "SELECT \"StockSymbol\", \"Unit\", \"Price\", \"ClearingFee\", \"StampDuty\", \"BrokerFee\""  + 
          "FROM SPM.\"StockBuy\" WHERE \"StockBuyId\" = '"+ stkbid + "'");
  
  System.out.println("Got stock buy details");
  
  ResultSet rs=stmtbuy.executeQuery();
  rs.next();
  //String stkcode = rs.getString("StockSymbol");
  Integer stkunit =  Integer.parseInt(rs.getString("Unit"));
  stkunit -= stock.getStockUnit();
  Double stkprice = Double.parseDouble(rs.getString("Price"));
  Double stkclear = Double.parseDouble(rs.getString("ClearingFee"));
  Double stksd = Double.parseDouble(rs.getString("StampDuty"));
  Double stkbfee = Double.parseDouble(rs.getString("BrokerFee"));
  Double stkval = stkunit * stkprice;
  Double stknv = stkval + stkval * (stkclear + stksd + stkbfee);
  
  System.out.println(stknv);
  
  PreparedStatement stmtbuy1 = conn.prepareStatement(
          "UPDATE SPM.\"StockBuy\" SET \"Unit\" = " + stkunit + ", \"Value\" = " + stkval + ", \"NetValue\" = " + stknv + 
          "WHERE \"StockBuyId\" = "+ stkbid);
  </code></pre>