Jump to content

Recommended Posts

Posted

I’m trying to create a table thru Dreamweaver CS4 titled emailSystem.

 

I build 14 others with no problem. Here is what I have…

 

<?php

require_once "connect_to_mysql.php";

print "Success in database CONNECTION.....<br />";

$tableCreate = "CREATE TABLE emailSystem (

mid int(11) NOT NULL auto_increment,

date date NOT NULL,

sender varchar(255) NOT NULL,

receiver varchar(255) NOT NULL,

title varchar(255) NOT NULL,

announcements longtext NOT NULL,

PRIMARY KEY (id),

UNIQUE KEY email (email)

)";

// This line uses the mysql_query() function to create the table now

$queryResult = mysql_query($tableCreate);

// Create a conditional to see if the query executed successfully or not

if ($queryResult === TRUE) {

print "<br /><br />Success in TABLE creation! Happy Coding!";

} else {

print "<br /><br />No TABLE created. Check";

}

// close mysql connection

mysql_close();

?>

 

What ‘am I missing?

 

Thanks, Scotty

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...