Refactored sql querying logic into instructor.utils and wired the html button and management command to it there