Jump to content
xisto Community
Sign in to follow this  
OliviaT

Mysql Database... A Simple Question... I Hope

Recommended Posts

I want to create a simple database on my computer to help develop a help form--but am stuck at a fundamental MySQL issue. I am using XAMPP to begin with and want to say the following:$connection=mysql_connect("localhost","",""); //yes, I want to work in a password and username free environment... I know the dangersmysql_select_db("help",$connection); //help is the name of my database, help_issue is the name of my table in the help database$query="UPDATE help_issue SET ID='NULL' First='$firstname' Last='$lastname' Badge='$badge' Phone='$phone' Email='$email' ComputerName='$computername' ComputerLocation='$computerlocation' Location='$location' Involves='$involves' Priority='$priority' Comments1='$comments' Comments2='$comments2' Assigned='$assigned' "; mysql_query($query);Is it possible to create a connection without a user and password? If not--how do I set one up in XAMPP? Any help would be greatly appreciated... I feel like beating my head into the wall at this point...

Share this post


Link to post
Share on other sites

Is it possible to create a connection without a user and password? If not--how do I set one up in XAMPP? Any help would be greatly appreciated... I feel like beating my head into the wall at this point...

 


No, it is not possible to create a connection without a username(as far as I know and my experience with databases concerned). But you can leave a password blank.

The default user for MySql database is root and password is blank (means no password).

 

So, if you have already created a database with the name help, then create a connection using root as username and password is empty string.

 

Ask me if you have any other doubts.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.