Re: odbc to emulate mysql for end programs

Поиск
Список
Период
Сортировка
От Andrew Sullivan
Тема Re: odbc to emulate mysql for end programs
Дата
Msg-id 20150602114735.GD92228@crankycanuck.ca
обсуждение исходный текст
Ответ на Re: odbc to emulate mysql for end programs  (Thomas Kellerer <spam_eater@gmx.net>)
Список pgsql-general
On Tue, Jun 02, 2015 at 01:31:55PM +0200, Thomas Kellerer wrote:
> > 2)  as program double-quotes the schema,table and column names.
>
> Don't use quoted identifiers. Neither in Postgres nor in MySQL (or any other DBMS)

I think a better rule of thumb is either always to use them (and spell
everything correctly) or never to use them.  Where you get in trouble
is the case where sometimes identifiers are quoted and sometimes not.
(I find the unquoted use more convenient, and I think it's subject to
fewer surprises like overloaded identifiers where one has an uppercase
in it; but I think that's a matter of taste, and if your system
framework quotes for you automatically then you have no choice but to
stick with that convention always and everywhere.)

This isn't really any different from any other development rule.  For
instance, in some environments there are various rules about single
and double quoting.  If you have no conventions imposed across all
your developers about when you use which, pretty soon you'll have an
unmaintainable mess.  And everyone has their favourite story of
frustration about indentation style or variable naming convention.
This case is no different.

A

--
Andrew Sullivan
ajs@crankycanuck.ca


В списке pgsql-general по дате отправления:

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: Minor revision downgrade (9.2.11 -> 9.2.10)
Следующее
От: Andrew Sullivan
Дата:
Сообщение: Re: advocating LTS release and feature-train release cycles