Read about GRANT queries in the mysql manual. You should definitely not be using your root info for web work -- in fact I'd create a user with SELECT only privs for most of it ...
GRANT SELECT on YOURDB.* to [EMAIL PROTECTED] identified by 'somepassword' Varying the YOURDB and the [EMAIL PROTECTED]/somepassword will give you different permutations of access by user to different databases ... varying the SELECT (adding additional permissions) will set the access rights. ... you can get more involved with specific tables/columns within tables -- but that should get you in the right direction. On Tue, Jul 24, 2001 at 10:40:26AM -0400, Aaron Traas wrote: > I currently have a database-driven web site up, with a PHP front end and > MySQL back-end. The problem I'm having is that the login for the > database is root and my root password. How do I change this? > > Also, I plan on having multiple web sites and thus multiple databases. > Can I tie a user and password to one specific database (or set of > databases) rather than giving said user access to all databases? > > Thanks in advance. > > --Aaron > > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- Hank Marquardt <[EMAIL PROTECTED]> http://web.yerpso.net Web & Database Development in PHP, MySQL/PostgreSQL Small Office Networking Solutions - Debian GNU/Linux & FreeBSD PHP Instructor - HTML Writers Guild <http://www.hwg.org> *** PHP II "The Cool Stuff" starts July 16, 2001 *** http://www.hwg.org/services/classes/p181.1.html