Professional Web Applications Themes

Simple Database Creation Question - MySQL

I'm hoping someone can help me. I'm trying to follow along with the book Baseball Hacks (excellent book by the way) and trying to learn MySQL so that I can follow along. Really intrigued by MySQL and would like to become proficient. However, I am stuck on step one. Probably a very stupid question.... I have intalled the newest version of MySQL and everything is fine. I can run MySQL Command Line Client. I have created a database called baseballtemp and I can see it is there when I run SHOW DATABASES. It is there. I have downloaded the .sql ...

  1. #1

    Default Simple Database Creation Question

    I'm hoping someone can help me. I'm trying to follow along with the
    book Baseball Hacks (excellent book by the way) and trying to learn
    MySQL so that I can follow along. Really intrigued by MySQL and would
    like to become proficient. However, I am stuck on step one. Probably
    a very stupid question....

    I have intalled the newest version of MySQL and everything is fine. I
    can run MySQL Command Line Client. I have created a database called
    baseballtemp and I can see it is there when I run SHOW DATABASES. It
    is there. I have downloaded the .sql file (called BDG-sql-2006-11-17)
    from the website and according to the directions in the book should be
    able to import the data into the baseballtemp database. I have placed
    the .sql file in the data folder in the MySQL Server 5.0 directory.
    So I try and run the MySQL command. I hit the start button (I'm
    running Windows XP by the way) and click on RUN. In the run box I
    insert the following line.

    mysql -u root -p -s baseballtemp < BDB-sql-2006-11-17.sql

    When I click on run the command shell opens up and quickly scrolls
    through a bunch of things so quickly I cannot read it. It takes a
    half a second at most. It's strange because it seems the -p switch
    should make me enter a password and it never does. Then I go into the
    MySQL command line client and type SHOW DATABASES. I can see the
    database there. But then I click on SHOW TABLES; as instructed in the
    book and I get a message there are no tables in this database. This
    doesn't make sense. I know there was about 38MB of data in this
    file.

    Can anyone give me some advice. I have been trying to get this to
    work all afternoon with absolutely no luck!!! Tearing my hair out.

    Thanks so much in advance. I sincerely apologize for being very naive
    about MySQL and asking a stupid question.

    DJENSE00@YAHOO.COM Guest

  2. #2

    Default Re: Simple Database Creation Question

    "COM" <COM> wrote in
    news:googlegroups.com:

     

    at RUN, type 'cmd' This will open up a permanent command-line window
    that won't close until you tell it to.

    from that new window, type the mysql command

     

    You've shown the databases, but i don't know if you've USEd one yet.
    Type "USE mydatabase", then select the tables

    Good Guest

  3. #3

    Default Re: Simple Database Creation Question

    COM wrote: 

    You need to get the errors being put out by MySQL. Try redirecting the
    output to a file, i.e.

    mysql -u root -p -s baseballtemp < BDB-sql-2006-11-17.sql > error.log 2>&1

    Or just change the properties for your window to give you a larger
    buffer (and save more lines in the window).

    --
    ==================
    Remove the "x" from my email address
    Jerry Stuckle
    JDS Computer Training Corp.
    net
    ==================
    Jerry Guest

Similar Threads

  1. Simple question - tab delimited file to database
    By robstacey in forum Macromedia ColdFusion
    Replies: 1
    Last Post: June 21st, 07:47 PM
  2. simple search database question
    By juniorbee in forum Dreamweaver AppDev
    Replies: 1
    Last Post: February 23rd, 10:38 PM
  3. Help with temp database creation
    By Thunder in forum ASP Database
    Replies: 3
    Last Post: November 21st, 04:44 PM

Bookmarks

Posting Permissions

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

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139