Queries to a database A. are written in English B. can use aggregate functions like SUM and COUNT C. both (a) and (b) D. All of the above E. None of the above

are written in English
can use aggregate functions like SUM and COUNT
both (a) and (b)
All of the above E. None of the above

The correct answer is: C. both (a) and (b)

Queries to a database can be written in English, and they can use aggregate functions like SUM and COUNT.

For example, the following query would return the total number of rows in the customers table:

SELECT COUNT(*) FROM customers;

The following query would return the total amount of money spent by customers in the last month:

SELECT SUM(amount_spent) FROM orders WHERE date_purchased > NOW() - INTERVAL 1 MONTH;

Aggregate functions are used to summarize data. They can be used to calculate the total, average, minimum, maximum, and count of values in a table.

I hope this helps! Let me know if you have any other questions.

Exit mobile version