I have two tables such as cisco and ciscocom. and i wan to compare each
row of ciscocom with cisco having same column values. i wan to get the
count of matching columns for each row in cisco...
eg:
Ciscocom has columns: Products,fw,ports,sec,des,tput etc and cisco has
columns:fw,ports,sec,des,tput etc. i wan the number of matching colum
for each row in ciscocom. please provide me with the procedure...
Waiting for your response...Try something like this:
SELECT COUNT(cisco.Products) FROM cisco INNER JOIN ciscocom
ON cisco.Products = ciscocom.Products
WHERE
cisco.Products='My_Value'|||On 1 Mar 2006 03:04:35 -0800, vvyshak@.gmail.com wrote:
>Hi all..
>I have two tables such as cisco and ciscocom. and i wan to compare each
>row of ciscocom with cisco having same column values. i wan to get the
>count of matching columns for each row in cisco...
>eg:
>Ciscocom has columns: Products,fw,ports,sec,des,tput etc and cisco has
>columns:fw,ports,sec,des,tput etc. i wan the number of matching colum
>for each row in ciscocom. please provide me with the procedure...
>Waiting for your response...
Hi Kuttan,
I just answered this question in microsoft.public.sqlserver.programming.
Please don't post seperate copies of the same question to several
groups!
--
Hugo Kornelis, SQL Server MVPsql
No comments:
Post a Comment