Results 1 to 2 of 2

Thread: mySQL 5.0 NO database selected Error when trying to create a table

  1. #1

    Thread Starter
    Hyperactive Member voidflux's Avatar
    Join Date
    Jun 2003
    Location
    Brockway, PA
    Posts
    290

    mySQL 5.0 NO database selected Error when trying to create a table

    Enter password: ********
    Welcome to the MySQL monitor. Commands end with ; or \g.
    Your MySQL connection id is 3 to server version: 5.0.27-community-nt

    Type 'help;' or '\h' for help. Type '\c' to clear the buffer.

    mysql> create table Category ( ID int unsigned not null auto_increment primary k
    ey, Category varchar(15) not null, CategoryID int unsigned not null, Isle int un
    signed not null, unique(Category, CategoryID) );
    ERROR 1046 (3D000): No database selected
    mysql>

    I set up mySQL sever to create an annynomius user so I wouldn't have to type a password and username in because I'm only going to be using this server locally on this machine.

    Any ideas how I can select a database first? Or how I create one?
    Thank you.
    C¤ry Sanchez
    Computer Science/Engineering
    @ Penn State
    IBM.zSeries Intern
    Mandriva 2007

  2. #2

    Thread Starter
    Hyperactive Member voidflux's Avatar
    Join Date
    Jun 2003
    Location
    Brockway, PA
    Posts
    290

    Re: mySQL 5.0 NO database selected Error when trying to create a table

    oops n/m i forgot:
    create database name;
    use name;
    C¤ry Sanchez
    Computer Science/Engineering
    @ Penn State
    IBM.zSeries Intern
    Mandriva 2007

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width