The table tbl_sites contains the following data:
-----------------------------------------------------
Userid sitename country
------------------------------------------------------
1 sureshbabu indian
2 PHPprogrammer andhra
3 PHP.net usa
4 PHPtalk.com germany
5 MySQL.com usa
6 sureshbabu canada
7 PHPbuddy.com pakistan
8. PHPtalk.com austria
9. PHPfreaks.com sourthafrica
10. PHPsupport.net russia
11. sureshbabu australia
12. sureshbabu nepal
13. PHPtalk.com italy
Write a select query that will displayed the duplicated
site name and how many times it is duplicated?

Answer Posted / thilip

SELECT sitename,COUNT(sitename) FROM tbl_sites GROUP BY
sitename

Is This Answer Correct ?    2 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is mysql a server?

457


Write a query to create a database and a table?

483


How many rows can be inserted in mysql at a time?

487


How to check if a record exists in a mysql database php?

437


What is indexing in mysql?

453






How does mysql store data?

513


How to find second highest salary from a table?

534


What is append query?

502


How does mysql store dates?

481


What is required to create mysql database?

510


What port is mysql running on?

468


How do you rename a table in mysql?

500


Why do gaps in sequences occur?

509


What does mysql flush tables do?

499


Can we rollback truncate in mysql?

512