for (Account acc : newAcc_lst) {
System.debug('to15format Test 1-> ' + acc.id);
Id to15convertString = acc.id;
System.debug('to15format Test 2-> ' + to15convertString);
String to15format = to15convertString.to15();
System.debug('to15format Test 3-> ' + to15format);
acc.id = to15format;
System.debug('to15format Test 4-> ' + acc.id);
}
update newAcc_lst;
DEBUGS:
to15format Test 1-> 0017Y0000testedQAJ
to15format Test 2-> 0017Y0000testedQAJ
to15format Test 3-> 0017Y0000tested
to15format Test 4-> 0017Y0000testedQAJ
So, the Id cannot be updated to new 15 characters Id. Why is the reason?