MySQL Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsDatabasesMySQL Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
Stop making mediocre tutorials.The best tutorials are video! Camtasia Studio makes it easy to create engaging, buzz-building screen videos at any size, in any popular format. Download the free trial!
  #1  
Old July 17th, 2000, 07:55 PM
Hartmann's Avatar
Hartmann Hartmann is offline
chown python:users\ /world
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jul 2000
Location: Texas Tech
Posts: 95 Hartmann User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 8
I am kind of new to MySQL. My question is, where do I put the Create Database and Create Table code???

IE.

CREATE TABLE posts (
ID int(5) DEFAULT '0' NOT NULL auto_increment,
TopicID int(5) DEFAULT '0' NOT NULL,
Name varchar(50) NOT NULL,
Email varchar(50) NOT NULL,
Password varchar(50) NOT NULL,
TimeStamp varchar(10) NOT NULL,
Post text NOT NULL,
PRIMARY KEY (ID)
);

CREATE TABLE topics (
ID int(5) DEFAULT '0' NOT NULL auto_increment,
TopicName varchar(50) NOT NULL,
PRIMARY KEY (ID)
);

Do I type this in the page where the database is called?


------------------
Hartmann

Reply With Quote
  #2  
Old July 18th, 2000, 08:07 AM
rway rway is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jul 2000
Posts: 26 rway User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Hello Hartman,

Judging from the code you have written you have defined your database and 2 tables. The coded that you will generate when you input data and extract data from these tables can be placed any where eg. embedded into html files etc. Read some articles on this website - thats how I have been learning. Good luck!

Richard

Reply With Quote
  #3  
Old July 18th, 2000, 08:11 AM
rway rway is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jul 2000
Posts: 26 rway User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Sorry reading your post again has shed your angle. Table data is stored on your server that has PHP and Mysql installed. I use a PHP administration software that allows me to update tables etc.

Richard

Reply With Quote
  #4  
Old July 18th, 2000, 09:27 AM
Hartmann's Avatar
Hartmann Hartmann is offline
chown python:users\ /world
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jul 2000
Location: Texas Tech
Posts: 95 Hartmann User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 8
Let me clarify.....

Would the code above be placed in a regular PHP file after created the Database?

Reply With Quote
Reply

Viewing: Dev Shed ForumsDatabasesMySQL Help > Create table...


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 4 hosted by Hostway