Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am building a ruby on rails application using mysql for storing application related data. My application has a user console and admin console. Access to admin console is restricted to administrators. How do I mark a user as admin in mysql database.

share|improve this question
Dunno. How does your application determine that someone is an admin? – Ignacio Vazquez-Abrams Nov 13 '10 at 16:36
Thanks. I thought it was a mysql configuration. Didn't know it was application dependent. – ardsrk Nov 13 '10 at 17:13

Easy to mark a user as admin inside of mysql -
add another mysql user as documented here:
and grant them appropriate permissions as documented here:

as to connecting to the database as separate users, that's another ball of wax with overriding methods...

or are you talking about making an admin flag in the users table...that's a column with the boolean type

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.