Microsoft
Software
Hardware
Network
Question : SQL Case
I have the following query, but i need to change it a little so that i have a case statement inserted.
SELECT
TblCustomer.TelNo1,
COUNT( TblCustomer.TelNo1) AS countDups
FROM
WHERE
(TblCustomerLog.CurrentCus
tomer = 1)
GROUP BY TelNo1
HAVING COUNT(TblCustomer.TelNo1)>
1
) AS a ON a.TelNo1 = TblCustomer.TelNo1
-- TblCustomer.TelNo1
-- (CASE
-- WHEN COUNT (TblCustomer.TelNo1) > 1
-- THEN 'Duplicate'
-- ELSE 'Unique'
-- END) AS countDups,
Answer : SQL Case
your code so far is a bit reduced, so it's not obvious to see where the subquery/join is happening
this must be removed, to get those with COUNT() = 1
HAVING COUNT(TblCustomer.TelNo1)> 1
Random Solutions
How do I reverse tunnel with Putty?
A Web Exception occurred because an HTTP 401 - Unauthorized response was received from Unknown
phpmailer errorInfo
emc cx600 - how do I get dell 64 bit server to see the emc harddrives
Exchange 2007 - Error 5.1.0 - Unknown address error 550-'5.1.1 User unknown'
Group By Sql Query
Switch 3Com 4800G doesn't save configuration ?
Drupal Frontpage - Views through PHP
SharePoint Recovery when all you have are the SQL files from disk ?
Exporting X509 published certificate information