CREATE TABLE captain (Captain_ID NUMBER, Name CLOB, Ship_ID NUMBER, age CLOB, Class CLOB, Rank CLOB)
CREATE TABLE Ship (Ship_ID NUMBER, Name CLOB, Type CLOB, Built_Year FLOAT, Class CLOB, Flag CLOB)

A stacked bar graph shows the total number of captains categorize by ranks of different classes, could you list in ascending by the x-axis?
SELECT Class, COUNT(Class) FROM captain GROUP BY Rank, Class ORDER BY Class
SELECT "Class", COUNT("Class") FROM "captain" GROUP BY "Rank", "Class" ORDER BY "Class"