CREATE TABLE STUDENT (STU_NUM NUMBER, STU_LNAME VARCHAR2, STU_FNAME VARCHAR2, STU_INIT VARCHAR2, STU_DOB DATETIME, STU_HRS NUMBER, STU_CLASS VARCHAR2, STU_GPA FLOAT, STU_TRANSFER NUMBER, DEPT_CODE VARCHAR2, STU_PHONE VARCHAR2, PROF_NUM NUMBER)
CREATE TABLE COURSE (CRS_CODE VARCHAR2, DEPT_CODE VARCHAR2, CRS_DESCRIPTION VARCHAR2, CRS_CREDIT FLOAT)
CREATE TABLE CLASS (CLASS_CODE VARCHAR2, CRS_CODE VARCHAR2, CLASS_SECTION VARCHAR2, CLASS_TIME VARCHAR2, CLASS_ROOM VARCHAR2, PROF_NUM NUMBER)
CREATE TABLE EMPLOYEE (EMP_NUM NUMBER, EMP_LNAME VARCHAR2, EMP_FNAME VARCHAR2, EMP_INITIAL VARCHAR2, EMP_JOBCODE VARCHAR2, EMP_HIREDATE DATETIME, EMP_DOB DATETIME)
CREATE TABLE ENROLL (CLASS_CODE VARCHAR2, STU_NUM NUMBER, ENROLL_GRADE VARCHAR2)
CREATE TABLE DEPARTMENT (DEPT_CODE VARCHAR2, DEPT_NAME VARCHAR2, SCHOOL_CODE VARCHAR2, EMP_NUM NUMBER, DEPT_ADDRESS VARCHAR2, DEPT_EXTENSION VARCHAR2)
CREATE TABLE PROFESSOR (EMP_NUM NUMBER, DEPT_CODE VARCHAR2, PROF_OFFICE VARCHAR2, PROF_EXTENSION VARCHAR2, PROF_HIGH_DEGREE VARCHAR2)

Find the total credits of all classes offered by each department Visualize by bar chart, and I want to display in ascending by the names.
SELECT DEPT_CODE, SUM(T1.CRS_CREDIT) FROM COURSE AS T1 JOIN CLASS AS T2 ON T1.CRS_CODE = T2.CRS_CODE GROUP BY T1.DEPT_CODE ORDER BY DEPT_CODE
SELECT "DEPT_CODE", SUM("T1"."CRS_CREDIT") FROM "COURSE" "T1" JOIN "CLASS" "T2" ON "T1"."CRS_CODE" = "T2"."CRS_CODE" GROUP BY "T1"."DEPT_CODE" ORDER BY "DEPT_CODE"