public static void insertStock(  int idarticle, int stock,int stockmin,int stockmaxi,Date datemaj,Float marge, Float ttc ) throws SQLException {

          String query="";          

        try {
            query = "INSERT INTO STOCK (ID_ARTICLE,STSTOCK,STMINI,STMAXI,STDATEMAJ,STMARGE,STTTC ) VALUES (?,?,?,?,?,?,?);";   
 
            PreparedStatement pStatement = ConnectionBDD.getInstance().getPreparedStatement(query);            
            pStatement.setInt(1,idarticle);
            pStatement.setInt(2, stock);
            pStatement.setInt(3,stockmin);
            pStatement.setInt(4, stockmaxi);
            pStatement.setObject(5, datemaj);
            pStatement.setFloat(6,marge );
            pStatement.setFloat(7,ttc );
            pStatement.executeUpdate();

        } catch (SQLException ex) {
            Logger.getLogger(RequetesStock.class.getName()).log(Level.SEVERE, null, ex);

        }
      }