+ 1
Help SQL practice 9.2 Brand new car
How do you sort company name by order? SELECT company, year FROM cars WHERE year = 2020; This is my coding for that practice question, but Iâm not able to sort the company name by order.
8 Answers
+ 2
ORDER by company;
+ 2
I mean
SELECT company, year
FROM cars
WHERE year = 2020
ORDER by company;
+ 2
Thanks guys i tried both of your coding and it works
+ 1
SELECT company, year
FROM cars
WHERE year = 2020
ORDER BY company ASC;
Try again this. It must be work. Adam Ali
+ 1
Hi
0
Add this line,
ORDER BY company ASC;
to order the company names by ascend.
I hope, it helps. Happy coding!
0
I tried both of your code -
SELECT company, year
FROM cars
ORDER BY company
WHERE year = 2020;
And ORDER BY company ASC
It still doesnt work.
0
SELECT COMPANY,YEAR
FROM CARS WHERE YEAR = 2020 ORDER BY COMPANY;