User type in MySQL database

User type in MySQL database

by Thomas Trần -
Number of replies: 3

Hi everyone. As I am working on a project for tracking online users, I have to involve the MySQL database. My question is that where can I find user types in my Moodle MySQL database? I've tried to look at table mdl_user but can not find it in here. Anyone have a suggestion? Thank you very much

Average of ratings: -
In reply to Thomas Trần

Re: User type in MySQL database

by Ray Hinton -
Hi Thomas,

It sounds like looking at the mdl_role_assignments and mdl_user_lastaccess tables might help you. I could be misinformed, but I am not aware of Moodle having "user types", per se, but rather all accounts are basically the same, and they are assigned roles with different capabilities at the appropriate context (system, category, course, user, activity, etc.). I hope some of that is helpful!

- Ray
In reply to Ray Hinton

Re: User type in MySQL database

by Thomas Trần -
Oh OK, let me try. Thanks very much. By the way, I want to ask for advice from you: I am making an online user tracking, for ex. if a teacher is online then it will notify the students. Do you have any idea that how I can build a function like this?
In reply to Thomas Trần

Re: User type in MySQL database

by Ray Hinton -
Hi Thomas,

Unfortunately, I do not know very much about PHP, plugin development, etc. Good luck!

- Ray