var sidebar_align = 'right';
var content_container_margin = parseInt('290px');
var sidebar_width = parseInt('270px');
Unanswered: Create Table with LIKE SyntaxProblem
I have a very simple problem with my syntax but I cant work it out...
I want to cretate a table with the same structure as an existing table. In the MySQL manual it defines the syntax:
CREATE [TEMPORARY] TABLE [IF NOT EXISTS] tbl_name (LIKE old_table_name);
However when I try to create my table
CREATE TABLE accidentsample (LIKE accident);
or various combinations such as ->
CREATE TABLE accidentsample LIKE accident;
I get the error:
ERROR 1064: You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'like accident)' at line 1
Wich I presume is a systatic parser error getting confused with 'LIKE' (Maybe because of the regex like command?)
Abyway, this should be really simple.. has anyone got this command to work, and if so can Iplease see the exact syntax?
Thanks a lot for your time!
| version() |
| 4.0.13-nt |
PS: MYSQL version =
Only works in MySQL version 4.1+.
Aye I as wonderin if it was something like that... Hence version number inclusion...
Cheers for you help! You saved me loads of time!