hello sam,
$query="create table test (ID integer(10) NOT NULL PRIMARY KEY, othercolumn VARCHAR(20) )";
$result = mysql_query($query) or die ("Invalid query");
see php.net:
"mysql_query
(PHP 3, PHP 4 >= 4.0.0)
mysql_query -- Send a MySQL query
Description
resource mysql_query ( string query [, resource link_identifier [, int result_mode]])
mysql_query() sends a query to the currently active database on the server that's associated with the
specified link identifier. If link_identifier isn't specified, the last opened link is assumed. If no link is open,
the function tries to establish a link as if mysql_connect() was called with no arguments, and use it.
The optional result_mode parameter can be MYSQL_USE_RESULT and MYSQL_STORE_RESULT. It defaults
to MYSQL_STORE_RESULT, so the result is buffered. See also mysql_unbuffered_query() for the
counterpart of this behaviour.
Note: The query string should not end with a semicolon.
Only for SELECT,SHOW,EXPLAIN or DESCRIBE statements mysql_query() returns a resource identifier or
FALSE if the query was not executed correctly. For other type of SQL statements, mysql_query() returns TRUE
on success and FALSE on error. A non-FALSE return value means that the query was legal and could be
executed by the server. It does not indicate anything about the number of rows affected or returned. It is
perfectly possible for a query to succeed but affect no rows or return no rows..."
hth
chris