I am trying to update a MS Access database. I have searched this and I have tried everything I have found but I am still getting the following error.
java.sql.SQLException: [Microsoft][ODBC Microsoft Access Driver] Syntax error in UPDATE statement.
Any help would be very helpful. My code is below...;
    String sqlStatement = "UPDATE ProductCatalogue"
            + "SET [StockLevel] = ?"
            + "WHERE [ProductID] = ?;";
    PreparedStatement prepStatement = connection.prepareStatement(sqlStatement);
    prepStatement.setInt(1, quantity);
    prepStatement.setInt(2, productID);
    //= "UPDATE ProductCatalogue"
    //+ "SET StockLevel = " + quantity
    //+ "WHERE ProductID = " + productID + ";";
    try {
        //myStatement.executeUpdate(sqlStatement);
        prepStatement.executeUpdate();
    } catch (SQLException sqle) {
        System.out.println("Oopss...." + sqle);
    }
    connection.close();
    prepStatement.close();