What is the difference between DISTINCT and GROUP BY?

Member

horace

by horace, in category: Technology , 8 months ago

What is the difference between DISTINCT and GROUP BY?

Facebook Twitter LinkedIn Telegram Whatsapp

1 answer

by julio.mcglynn , 8 months ago

DISTINCT can return NULL values because it considers NULL as a value and selects one NULL from many, however, GROUP BY does not consider NULL values as a record. GROUP BY sorts the records where DISTINCT does not.