PC(code, model, speed, ram, hd, cd, price)
Find the hard drive sizes that are equal among two or more
PCs.



Answers were Sorted based on User's Feedback



PC(code, model, speed, ram, hd, cd, price) Find the hard drive sizes that are equal among two or mo..

Answer / sandeep

Select hd from PC
Group by hd
having count(hd)<>1

Is This Answer Correct ?    16 Yes 1 No

PC(code, model, speed, ram, hd, cd, price) Find the hard drive sizes that are equal among two or mo..

Answer / cullen

Select hd from PC
Group by hd
having count(*)>=2

Is This Answer Correct ?    4 Yes 0 No

PC(code, model, speed, ram, hd, cd, price) Find the hard drive sizes that are equal among two or mo..

Answer / piko1989

Select distinct hd
from pc
GROUP BY hd
having count(hd)>=2

Is This Answer Correct ?    1 Yes 0 No

PC(code, model, speed, ram, hd, cd, price) Find the hard drive sizes that are equal among two or mo..

Answer / alci

Select hd
from PC
group by hd
having count(hd)>1

Is This Answer Correct ?    1 Yes 0 No

PC(code, model, speed, ram, hd, cd, price) Find the hard drive sizes that are equal among two or mo..

Answer / rafal

select hd
from PC
group by hd having count(model) >= 2

Is This Answer Correct ?    0 Yes 0 No

PC(code, model, speed, ram, hd, cd, price) Find the hard drive sizes that are equal among two or mo..

Answer / guest

Select * from PC
group by hd
having count(*)>1

Is This Answer Correct ?    6 Yes 7 No

Post New Answer

More SQL Server Interview Questions

how do you implement one-to-one, one-to-many and many-to-many relationships while designing tables? : Sql server database administration

0 Answers  


How to end a stored procedure properly in ms sql server?

0 Answers  


What are the fixed server level roles? : sql server security

0 Answers  


how do you test proper tcp/ip configuration windows machine? : Sql server database administration

0 Answers  


Explain what is the purpose of sql profiler in sql server?

0 Answers  






What do you mean by recursive stored procedure?

0 Answers  


Table - Products has number of products as below Productid ProductName 1 iPhone 2 iPad 3 BlackBerry Table - SalesPersonProduct has the below records Salespersonid productid S1 1 S1 2 S1 3 S2 1 S3 2 Write a SQL query that returns the number of sales for each product

2 Answers  


What is the purpose of using COLLATE in a query?

1 Answers  


Tell me time data type, datetime2, datetimeoffset data type in sql server 2008?

0 Answers  


What is the minimum recommended amount of ram for sql server 2012 enterprise?

0 Answers  


What are the advantages to use stored procedures?

0 Answers   Ernst Young,


How many types of cursor type are there?

0 Answers  


Categories