ok, i'm running all this off my own computer. WinXP with apache 1.3.x. How can i create a database? So far I've searched online and found these answers:

  1. create through a php page

  2. create through phpmyadmin

  3. create through dos prompt

But i had problems with all three respectively

  1. Warning: MySQL Connection Failed: Can't connect to MySQL server on 'localhost' (10061) in c:\dn\nuclub\datatest.php on line 5
    Unable to select database

  2. couldnt get phpmyadmin to work

  3. dos prompt didnt know what it was
    -----------------------------

I know i have mysql installed because phpinfo says its cool. Something i thought i noticed while looking around in different tutorials was that something was always mentioned about connecting to a database first. How can you connect to a database that isnt created yet. And one of them said that i need to "know my username and password" dont i have to create a username and password first?

    Steps to getting MySQL set up on windows:

    1. Run the installer
    2. Go to c:\mysql\bin and run winMySQL Admin.exe
      When you do this, you will be prompted to create a user name and password.
    3. At this point MySQL should be up and running. winMyMySQLAdmin generally runs at start up too, so when you boot your system, it should already be on.
    4. If it has not started, do what is in step 2. (this time you wont be prompted to create a username/password)
    5. If all else fails here is how to use the dos prompt

    a. press windows+r
    b. type command into the box
    c. the window that just opened is the dos prompt
    d. type in cd c:\mysql\bin
    e. type in mysqld , and MySQL should be started and ready for use.

    To create a databse, read the MySQL documentation for the SQL syntax.

      Concerning the Phpmydamin, you said it was not working but what error message did you get ?
      Also, did you open the config.inc.php to change some settings suit for your Mysql ? For example :
      $cfgServers[1]['host'] = '';
      $cfgServers[1]['auth_type'] = '';
      $cfgServers[1]['user'] = '';
      $cfgServers[1]['password'] = '';
      $cfgServers[1]['only_db'] = '';
      etc.,
      i think you'd better check the documenatations about the config of the phpmyadmin.

        Ok so i figured out how to create a database with winmysqladmin.

        1. Now how do i find out what my username and password is?
        2. Is that set up when mysql is installed? can i edit them in winmysqladmin?
        3. If i dont remember ever setting a username and password up does that mean there is none?
        4. Does each database have its own username and password?

          winmysqladmin does not create databases. but when you ran it, it should have asked you to create a user name and password.

          if you forgot what you put as your user name and password, it is really easy to get, run winmysqladmin, click on the my.ini setup tab, and it will display your user name and password.

            Write a Reply...