How to use BigInteger?

BigInteger is immutable. The javadocs states that add() “[r]eturns a BigInteger whose value is (this + val).” Therefore, you can’t change sum, you need to reassign the result of the add method to sum variable. sum = sum.add(BigInteger.valueOf(i));

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)