comparing tables and dealing with null value
Posted on 2010-01-07
I have two tables, both contain similar data. table A contains today's values, and table B contains yesterday's values.
I'm trying to create a query that will compare all values in A and B, and find only the items that had changes.
only issue that i am running into is that some fields may contain null, which is keeping securities that have null on both sides to also show up. e.g.
if field1 is null on both sides
tableA.field1 = tableB.field1 results in false.
how can i go about doing this? right now, i was planning on creating two queries, one that shows all securities that match, and then from that derive a query that shows only the missing.