Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in SQL by (55.6k points)

Can anyone tell me how to remove duplicate rows in SQL?

1 Answer

0 votes
by (119k points)

For example, if we want to print distinct values of “ColumnA, ColumnB, and ColumnC”, we use group by all the three columns. The following query is the simplest and easiest way to remove duplicate rows in SQL.

SELECT distinct ColumnA, ColumnB, ColumnC

FROM table_name

You can go through this SQL tutorial blog for more such simple tricks.

Related questions

0 votes
1 answer
asked Jul 4, 2019 in SQL by Tech4ever (20.3k points)
0 votes
1 answer
0 votes
1 answer
0 votes
1 answer
asked May 5, 2020 in SQL by Sudhir_1997 (55.6k points)

Browse Categories

...