CREATE TABLE student (id CLOB, name CLOB, dept_name CLOB, tot_cred NUMBER)
CREATE TABLE course (course_id CLOB, title CLOB, dept_name CLOB, credits NUMBER)
CREATE TABLE section (course_id CLOB, sec_id CLOB, semester CLOB, year NUMBER, building CLOB, room_number CLOB, time_slot_id CLOB)
CREATE TABLE takes (id CLOB, course_id CLOB, sec_id CLOB, semester CLOB, year NUMBER, grade CLOB)
CREATE TABLE advisor (s_id CLOB, i_id CLOB)
CREATE TABLE prereq (course_id CLOB, prereq_id CLOB)
CREATE TABLE time_slot (time_slot_id CLOB, day CLOB, start_hr NUMBER, start_min NUMBER, end_hr NUMBER, end_min NUMBER)
CREATE TABLE department (dept_name CLOB, building CLOB, budget NUMBER)
CREATE TABLE teaches (id CLOB, course_id CLOB, sec_id CLOB, semester CLOB, year NUMBER)
CREATE TABLE classroom (building CLOB, room_number CLOB, capacity NUMBER)
CREATE TABLE instructor (id CLOB, name CLOB, dept_name CLOB, salary NUMBER)

Find the name of instructors who are advisors of the students from the Math department, and sort the results by students' total credit.
SELECT T2.name FROM advisor AS T1 JOIN instructor AS T2 ON T1.i_id = T2.id JOIN student AS T3 ON T1.s_id = T3.id WHERE T3.dept_name = 'Math' ORDER BY T3.tot_cred
SELECT "T2"."name" FROM "advisor" "T1" JOIN "instructor" "T2" ON "T1"."i_id" = "T2"."id" JOIN "student" "T3" ON "T1"."s_id" = "T3"."id" AND "T3"."dept_name" = 'Math' ORDER BY "T3"."tot_cred"