Another migration bug...
I am amazed migration works at all sometimes ;-)
See https://code.vtiger.com/vtiger/vtigercrm/blob/master/modules/Migration/schema/600_to_610.php#L708
Look at the var declared as $numOfRowas
. In the for loop on the next line it is using $numOfRows
which is actually set in an earlier query on line 174...