...

View Full Version : Creating table in MySQL db



gsnedders
06-07-2004, 10:35 PM
I have this
CREATE TABLE `email2` ( `email` VARCHAR( 255 ) NOT NULL ,' . ' `name` VARCHAR( 255 ) NOT NULL ,' . ' PRIMARY KEY ( `email` ) ,' . ' INDEX ( `name` ) ) but it isn't working...

missing-score
06-07-2004, 11:09 PM
I dont understand, why do you have those ' . ' s in there?

gsnedders
06-07-2004, 11:11 PM
It was made with phpMyAdmin...

missing-score
06-07-2004, 11:12 PM
Go through the phpMyAdmin wizard and create a table with that setup and then copy the outputted SQL code... If it doesnt work in your script then the chances are your database connection is failing.

Nightfire
06-07-2004, 11:49 PM
Also, next time when something "doesn't work", show us the error.

gsnedders
06-08-2004, 12:01 AM
Also, next time when something "doesn't work", show us the error.

There was no error, it just didn't create it...

MrShed
06-08-2004, 10:40 AM
Yeh probably just no error because you didn't check for an error tho :p.

How are you actually passing that in your script? Show us a couple of lines of code, with the query etc. Those ' . ' bits are probably screwing it up for a start, but don't know for sure until i see the code.

gsnedders
06-08-2004, 07:17 PM
How are you actually passing that in your script? Show us a couple of lines of code, with the query etc. Those ' . ' bits are probably screwing it up for a start, but don't know for sure until i see the code.

I know the rest works, it's tested with 2 other commands ;)

MrShed
06-08-2004, 07:35 PM
yeh im not saying it doesnt work....but give us a bit of the context of the query to work with. For example what uve given us isn't php code at all.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum