Friday, November 21, 2008

Mysql as Database for Script

Its often necessary to maintain data in a table over the server.Scripting language enable the developer to connect to the database and get the data. Here we are going to setup a free community database software mysql version 5.1.2600. Mysql is been supported by php right from beginning of its journey. Lets see how to install and then configure php for mysql.

Download the mysql installation file 'mysql-5.0.67-win32.zip'and install it just by clicking next and next, after extrating to temp directory.During installation check the option to install mysql as a service. So that mysql can be started from from command prompt as follows,

RUN COMMAND :cmd
------------------------------------------------------
>mysql -u root -p
Enter Password:*******

>mysql>
------------------------------------------------------

Prompt appears asking password , give a valid password(created during installation) to work with mysql.
Right now mysql is been installed but it still need to be configured with PHP for php code access Mysql database.Configuring PHP for mysql will be discussed in next post.

No comments: