Hi,
It's a great script that you have given us. Very handy to verify ETL migrations programmatically.
Just to add (probably most of you already know this), there is a tool that comes with SQL Server called "TableDiff", which pretty much does the same. Only thing, it is a command prompt tool!
Thanks,
Shiva.
---------
Cheers,
Shiva.