Need to create a very simple database structure using mySQL

Questions about the MySQL, PostgreSQL, and most other databases, as well as using it with PHP can be asked here.

Moderator: General Moderators

Post Reply
rgeorgiou
Forum Newbie
Posts: 1
Joined: Fri Jun 06, 2008 4:02 pm

Need to create a very simple database structure using mySQL

Post by rgeorgiou »

Hi experts,

I've created a web site http://www.lastrap.co.uk which works very well. It's situated on a linux box with PHP and mySQL. I would like to add a mySQL database but to be honest, I've only ever dealt with access databases. I'm quite confident that I can create the PHP but I have no idea how to create the actual database. I've looked for a tutorial on the subject but can't seem to find anything. Could anyone point me to a decent but simple tutorial for creating a mySQL database please.

Kindest regards, your time is appreciated.
Richard Georgiou
http://www.lastrap.co.uk
User avatar
chopper_pc
Forum Newbie
Posts: 15
Joined: Fri May 30, 2008 10:55 pm

Re: Need to create a very simple database structure using mySQL

Post by chopper_pc »

http://www.tizag.com/mysqlTutorial/
I think this was the first tutorial I used (fairly new here mysef).
Good tutorial because it will introduce you too a tool called phpmyadmin, which is a web based Mysql administration tool written in php. Very usefull. It will walk you through connecting to your database w/ php for the first time, and show you how to create tables etc. Once you get the ball rolling everything should start to fall into place depending how much google/try/fail/google again/try/fail...... time you got.
Hope that helps.

Joe
User avatar
califdon
Jack of Zircons
Posts: 4484
Joined: Thu Nov 09, 2006 8:30 pm
Location: California, USA

Re: Need to create a very simple database structure using mySQL

Post by califdon »

That's a good starting point. Also you can search on Google or wherever for mysql tutorial and you will find dozens of good tutorials.

If you want to install phpmyadmin (if your site is hosted at a commercial web hosting site, you may already have it available), that's the easiest way for a beginner to create or modify a MySQL database, but you can do those things with SQL commands, too, such as CREATE DATABASE ..., CREATE TABLE ..., etc. The SQL commands can be executed on a command line if you have access to such on the server, or you can use them within a PHP script, after connecting to the MySQL server host.

The underlying principles of all relational databases are exactly the same, but you won't have all the nice GUI tools that MS provides in Access (but you'll have a much more capable and reliable database engine!). Be aware that the design of your schema (database/table structure) is the single most important factor in getting a database to do what you want it to do. If you understand relational databases from your Access background, fine, but if not, I strongly recommend that you study some relational database tutorials before going much further.
Post Reply