4 Please write a querry to find repeated numbers in the
following table.
Table Name: Table1
Field1
10
15
20
15
10
Answers were Sorted based on User's Feedback
Answer / lalit pandey
SELECT field1,count(field1) "Number of Occurrence"
FROM table1
GROUP BY field1
HAVING COUNT(field1)>1;
| Is This Answer Correct ? | 37 Yes | 0 No |
Answer / pritesh
SELECT field1
FROM table1
GROUP BY field1
HAVING COUNT(field1)>1;
| Is This Answer Correct ? | 8 Yes | 0 No |
Answer / murtaza
SELECT COUNT(FIELD1)AS "NO OF OCCURENCES"
FROM TABLE1
WHERE FIELD1 BETWEEN 10 AND 15
| Is This Answer Correct ? | 0 Yes | 2 No |
Answer / anjali
select count (distinct columnname)
from tablename
| Is This Answer Correct ? | 1 Yes | 5 No |
Answer / vivek
Select distinct Field1 from Table1 where Field1 between 10
and 15
| Is This Answer Correct ? | 2 Yes | 17 No |
There are two tables (T1, T2) with different rows. Find the output of query. Select count(*) from T1,T2.
What happens if you are trying to access a schema not owned by you?
Tell me what is the difference between locking and multi-versioning?
What is log in sql server?
What authentication modes does sql server support?
Do you think BCNF is better than 2NF & 3NF? Why?
How each E-R model constructs can be mapped to the relational model?
What is the recovery model?
how to take backup bcp out for a column in table in sql server?
How to insert multiple rows with one insert statement in ms sql server?
How to get a list of columns using the "sys.columns" view in ms sql server?
What is the sql case statement used for?
Oracle (3259)
SQL Server (4518)
MS Access (429)
MySQL (1402)
Postgre (483)
Sybase (267)
DB Architecture (141)
DB Administration (291)
DB Development (113)
SQL PLSQL (3330)
MongoDB (502)
IBM Informix (50)
Neo4j (82)
InfluxDB (0)
Apache CouchDB (44)
Firebird (5)
Database Management (1411)
Databases AllOther (288)