你进行的什么操作呀?看问题就是 @P2and 定义呗。

解决方案 »

  1.   


    我用到数据库更新的语句static final String SET_POSITION = "update DBR set position = ? where play_id = ?and round_flag =1 and life_flag=1";
      

  2.   

    调用过程
               public  void setPlace(int num,int playId){
    Connection conn = null;
    try{
    PreparedStatement prestm = null;
    //ResultSet rs = null;
    synchronized (this) {
    conn = dataSource.getConnection();
    prestm = conn.prepareStatement(SET_POSITION);
    prestm.setInt(1,num);
    prestm.setInt(2,playId);  prestm.execute();
    }
    prestm.close();
    conn.close();
    }catch (SQLException ex) {
    ex.printStackTrace();
    } finally {
    try {
    if (conn !=  null) {
    conn.close();
    }
    } catch (SQLException ex) { }
    }

    }
      

  3.   

    问题解决了
    where play_id = ?and round_flag   中的? 和and 之间应该有个空格
    刚才急死了 !!!^_^