working sql for view my courses