On Mon, Dec 24, 2001 at 11:31:45PM +0200, Heikki Tuuri wrote:
: Use the following:
: 
: CREATE TABLE `wishlist` (
:                 `wishlist_id` int(11) NOT NULL auto_increment,
:                 `user_id` int(11) NOT NULL,
:                 PRIMARY KEY (`wishlist_id`),
:                 INDEX `wishlist_user_id_ind` (`user_id`),
:                 FOREIGN KEY (user_id) REFERENCES user (user_id)
:                 ) TYPE = innodb;
: 
: That will work. By the way, why do many people write table and column names
: in quotes? What is the origin of that convention? Avoiding reserved words?

Case sensitivity on some databases (ones that I've worked with
include PostgreSQL) require quotes.  Otherwise, things go in all
lowercase.

Many people write code to be database agnostic because it makes
upgrading backends easier.  I believe the quotes are allowed under
the SQL92 standard, but don't quote me on that.

* Philip Molter
* Texas.net Internet
* http://www.texas.net/
* [EMAIL PROTECTED]

---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to