|
Posted by Toby A Inkster on 11/15/07 12:47
Tim Roberts wrote:
> Sanders Kaufman wrote:
>
>> I was under the impression that square braces were the way to go:
>> $sSQL = "DROP TABLE IF EXISTS [products]";
>
> No, that's a Microsoft extension that only works in Access. It isn't SQL.
And Microsoft SQL Server since, IIRC, version 7... or whenever it was they
started to really diverge from the Sybase code. (Microsoft SQL Server was
originally a re-badged version of Sybase SQL Server.)
The SQL-compliant way of quoting table names is to use double-quotes. But
since the OP was using MySQL, which doesn't support the SQL-compliant
method (not by default anyway), that wouldn't work.
--
Toby A Inkster BSc (Hons) ARCS
[Geek of HTML/SQL/Perl/PHP/Python/Apache/Linux]
[OS: Linux 2.6.12-12mdksmp, up 8 days, 19:40.]
TrivialEncoder/0.2
http://tobyinkster.co.uk/blog/2007/08/19/trivial-encoder/
Navigation:
[Reply to this message]
|