You have a table ABC with columns a and b. You now want to use a multiple-argument aggregate function to display a in descending order of b. To do this, you have written the following two queries.
SELECT string_agg(a, ‘,’ ORDER BY b) FROM ABC;
SELECT string_agg(a ORDER BY b, ‘,’) FROM ABC;
Which of these queries is an incorrect way to implement the given objective?
- Only A
- Only B
- Both A and B
- Neither A nor B