Move sqlmm to member functions