Before I begin i'm sorry if this is a noobish question. Basically I'm trying to import a 'forum.sql' file into mysql so that I can access and manipulate it through a Java servlet.

The path to the sql dump file is /home/floyd/Desktop/forum/forum.sql so i open a terminal window, cd into that directory and type:

floyd@floyd:~/Desktop/forum$mysql -u root -p root forum < forum.sql

Then i get this...

mysql Ver 14.12 Distrib 5.0.67, for debian-linux-gnu (x86_64) using readline 5.2
Copyright (C) 2000-2008 MySQL AB
This software comes with ABSOLUTELY NO WARRANTY. This is free software,
and you are welcome to modify and redistribute it under the GPL license
Usage: mysql [OPTIONS] [database]
-?, --help Display this help and exit.
-I, --help Synonym for -?
--auto-rehash Enable automatic rehashing. One doesn't need to use
'rehash' to get table and field completion, but startup
and reconnecting may take a longer time. Disable with
-A, --no-auto-rehash
No automatic rehashing. One has to use 'rehash' to get
table and field completion. This gives a quicker start of
mysql and disables rehashing on reconnect. WARNING:
options deprecated; use --disable-auto-rehash instead.
-B, --batch Don't use history file. Disable interactive behavior.
(Enables --silent)


auto-rehash TRUE
character-sets-dir (No default value)
default-character-set latin1
comments FALSE
compress FALSE
database (No default value)
delimiter ;
vertical FALSE
force FALSE


max_join_size 1000000
secure-auth FALSE
show-warnings FALSE

Then I start mysql and try and view the database but the database is not there...

floyd@floyd:~/Desktop/forum$ mysql
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 42
Server version: 5.0.67-0ubuntu6 (Ubuntu)

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

mysql>show databases;
| Database |
| information_schema |
1 row in set (0.00 sec)

Where do I go from here? How can I actually be sure the database has or hasn't been imported? How to view the database so i know what fields i need to access?!?

Any help is much appreciated,
Many thanks

7 Years
Discussion Span
Last Post by mwasif

First create a database named forum by executing the following command on mysql prompt


Edited by mwasif: n/a

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.