App Logo

No.1 PSC Learning App

1M+ Downloads
Which SQL aggregate function returns the total number of unique values in a column?

ACOUNT (DISTINCT column)

BTOTAL (DISTINCT column)

CUNIQUE (column)

DDISTINCT (column)

Answer:

A. COUNT (DISTINCT column)

Read Explanation:

  • The COUNT DISTINCT function returns the number of unique values in the column or expression, as the following example shows.
  • SELECT COUNT(DISTINCT column_name) FROM table_name; This simple query provides you with the frequency of unique values in the respective column of the passed table.
  • It's a very useful feature in SQL for tasks like finding the number of different categories, unique customers, or distinct items in your dataset.

Related Questions:

Primary output device is
Combination of analogue and digital computers are called
How many keys are on a keyboard?
Language used in first generation computers is

Choose the correct one from the following statements.

  1. A modem is a device that allows access to the internet through telephone lines.

  2. The Webby Awards are the Oscars of the Internet.

  3. Wikipedia is the world’s largest free encyclopedia