Re: Complicated database problem
- From: Bill Karwin <bill@xxxxxxxxxx>
- Date: Sun, 17 Jul 2005 12:08:56 -0700
Paul wrote:
For starters, FROM and TO are reserved words in SQL, so *_DO NOT_* use them as your column names.
That's a bit too strict. Many modern RDBMS products support quoted identifiers, specifically so you can use reserved words as table names, column names, etc. (or identifiers with international characters, whitespace, and so on).
In ANSI/ISO SQL, quoted identifiers are set off by double-quotes:
SELECT * FROM "TABLE"
MySQL unfortunately differs from the standard and uses backticks:
SELECT * FROM `TABLE`
Though it is a reasonable recommendation to avoid using reserved words in a schema, because then you don't have to remember to use quoted identifiers.
Regards, Bill K. .
- Follow-Ups:
- Re: Complicated database problem
- From: Paul
- Re: Complicated database problem
- References:
- Complicated database problem
- From: bilaribilari
- Re: Complicated database problem
- From: Paul
- Complicated database problem
- Prev by Date: Re: Database design pattern question
- Next by Date: Re: Database design pattern question
- Previous by thread: Re: Complicated database problem
- Next by thread: Re: Complicated database problem
- Index(es):
Relevant Pages
|