I know the basics of how to create tables in mySQL....but I cant figure out how to get field names that have more than one word (basically, names that have spaces in them)
Is this even possible?
Here's What i have so far:
$sql = "CREATE TABLE $username ( $field1 VARCHAR (255) DEFAULT '0' not null , $field2 VARCHAR (255) DEFAULT '0' not null , $field3 VARCHAR (255) DEFAULT '0' not null , $field4 VARCHAR (255) DEFAULT '0' not null , $field5 VARCHAR (255) DEFAULT 0 not null , $field6 VARCHAR (255) DEFAULT '0' not null , $field7 VARCHAR (255) DEFAULT '0' not null) comment = 'User Table'";
What its supposed to do is create a table in the name of the user (ex: alundrigan) and create 7 fields that the user names (defaults: ID, Departing City, Destination City, Departing Time, Arrival Time, Aircraft, Frequency)
How would I go about getting this to work. I've tried everything my limited PHP knowledge allowed me to.
-Adam Lundrigan
CEO, VPU
<!-- m --><a class="postlink" href="http://www.vpu-virtual.com">http://www.vpu-virtual.com</a><!-- m -->
Is this even possible?
Here's What i have so far:
$sql = "CREATE TABLE $username ( $field1 VARCHAR (255) DEFAULT '0' not null , $field2 VARCHAR (255) DEFAULT '0' not null , $field3 VARCHAR (255) DEFAULT '0' not null , $field4 VARCHAR (255) DEFAULT '0' not null , $field5 VARCHAR (255) DEFAULT 0 not null , $field6 VARCHAR (255) DEFAULT '0' not null , $field7 VARCHAR (255) DEFAULT '0' not null) comment = 'User Table'";
What its supposed to do is create a table in the name of the user (ex: alundrigan) and create 7 fields that the user names (defaults: ID, Departing City, Destination City, Departing Time, Arrival Time, Aircraft, Frequency)
How would I go about getting this to work. I've tried everything my limited PHP knowledge allowed me to.
-Adam Lundrigan
CEO, VPU
<!-- m --><a class="postlink" href="http://www.vpu-virtual.com">http://www.vpu-virtual.com</a><!-- m -->