This doesn't really have anything to do with Php but I'm following a php tutorial so...I've NEVER used any database system before...

Anyway,
I'm following this tutorial,
http://buildingbrowsergames.com/2008/04/15/designing-your-database/

I'm up to the part where your making the user sql table in the tutorial. I have no idea where to input that code..
Where do you put the code?

CREATE TABLE users (
	id int NOT NULL AUTO_INCREMENT,
	username varchar(250),
	password varchar(50),
	PRIMARY KEY(id)
);

Sorry to hear about your "suckiness"!

Grab a copy of phpmyadmin to make your life easier.
It's a gui interface for MySql. Works great. Don't code without it!
Otherwise, you can do command line Mysql if you want to be "hard-core".
BTW i assume that you have MySQL installed-right?

I have MySql Workbench, Is that good or should i get phpmyadmin?

Also, How can i make this codes with mysql workbench...
Like how many rows/collums ect.

CREATE TABLE users (
      id int NOT NULL AUTO_INCREMENT,
      username varchar(250),
      password varchar(50),
      PRIMARY KEY(id)
      );

creating that table will create 3 columns

id, username, password

to add more rows use the insert syntax

insert into users set
username = 'any name you want',
password = 'any password you want';

//or

INSERT INTO users
(username, password) VALUES
('any name you want', 'any password you want' );
Member Avatar for rajarajan2017

Mr nsutton ,

Before starting to work with your php files, first of all you have to know about the php running environment, about creating databases, execution method and all.

Follow the methods:
1) Install XAMP (google it and download the copy)
2) Install in your local system by following the instructions
3) Open XAMPP control panel in relevant installed path, and check whether apache (web server) and DBMS (My-sql) is checked and running properly.
4) open browser, type : http://localhost
5) If you see XAMP page then it is successful

Then follow any tutorials to know php and sql. you query has to be create in mysql database.

I have MySql Workbench, Is that good or should i get phpmyadmin?

I an not familiar with MySql Workbench. If you are going to do this kind of work, many hosting services use phpmyadmin, so getting familiar with it is a good idea. It' open source software, no $$ required.

You might want to check out the Mysql site for tutorials, etc, so you can see how it works.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.