Hi,
This is in reference towards Dev Shed's PHP 101 4th tutorial(http://www.devshed.com/Server_Side/PHP/PHP101/PHP101_4/page2.html). I'm stuck on how I would create tables in mySQL after all, I have no experience with it. I have tried searching the forums for an answer, but with no luck.
My problem: I don't know how to create the mySQL table this tutorial is asking me to do. The dump file link seems to be broken on that page I linked to above at the top of my post. The tutorial also tells me to use this command:
mysql> mysql -u username -p database < dumpfile
If I were to use a dumpfile, I would I go about using this command? I have phpMyAdmin on my webserver as well as SSH access to my webserver as well. Where abouts is the mySQL prompt? I am using putty btw as my SSH client.
Now if I were to create the tables manually, the tutorial tells me to use this:
Table structure for table 'url_list'
CREATE TABLE url_list (
uid varchar(8) NOT NULL,
title1 varchar(30) NOT NULL,
url1 text NOT NULL,
title2 varchar(30) NOT NULL,
url2 text NOT NULL,
title3 varchar(30) NOT NULL,
url3 text NOT NULL,
PRIMARY KEY (uid)
);
Dumping data for table 'url_list'
INSERT INTO url_list VALUES( 'john', 'Melonfire',
'http://www.melonfire.com', 'Devshed',
'http://www.devshed.com', 'PHP.Net',
'http://www.php.net');
INSERT INTO url_list VALUES( 'bill', 'Yahoo',
'http://www.yahoo.com',
'Slashdot', 'http://www.slashdot.org', '32Bit.com',
'http://www.32bit.com');
I put this in using phpMyAdmin by running a SQL query, and I hope i did that right. The tutorial says I can check if I did it right by using this command but I don't know where to use this as well.
mysql> select count(*) from url_list;
Thanks in advance for reading my long post. If there are any inillegibilities, sorry.