You can use CHECKSUM() or BINARY_CHECKSUM() function.
SELECT *
FROM tbl1
JOIN tbl2 ON tbl1.pk = tbl2.pk
AND CHECKSUM(tbl1.col2, tbl1.col3) <> CHECKSUM(tbl2.col2, tbl2.col3)
Check also
http://decipherinfosys.wordpress.com/2009/02/11/another-use-of-the-checksum-functions/>
>How's it going? Yep, I want to compare all data, every column, every row. There is a primary key. I have rewritten a process that inputs 10 of thousands of records every night. So I want to compare the data in the new process to the old one. I have it written in Foxpro, where I scan, seek every record and compare the value in every field. It works fine, but I was just wondering if SQL Server had some niffty comand or tool.
>BTW, I had a problem with the LEN command the other day and looked it up here on the thread, and you stated to some one to use DataLength instead.. thanks!
>
>Thanks!
--sb--