How to search the greatest count among four temporary table.
Posted on 2011-02-16
I have four temporary tables, they are billingaddress, postaladdress, shippingaddress, officeaddress now there are different number of rows in each table. I want to find out which of them has highest number of rows and assign the variable @x that value. how to get the highest count(*) among 4 #temporary tables?