Re: [PATCHES] dollar quoting

Поиск
Список
Период
Сортировка
От Andrew Dunstan
Тема Re: [PATCHES] dollar quoting
Дата
Msg-id 4027311E.9090907@dunslane.net
обсуждение исходный текст
Ответ на Re: [PATCHES] dollar quoting  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers

Tom Lane wrote:

>A bigger problem here:
>
>
>
>>+             else if (!dol_quote && line[i] == '$' &&
>>+                      !isdigit(line[i + thislen]) &&
>>+                      (dol_end = strchr(line+i+1,'$')) != NULL &&
>>+                      (i == 0 ||
>>+                       ! ((line[i-1] & 0x80) != 0 || isalnum(line[i-1]) ||
>>+                          line[i-1] == '_')))
>>+             {
>>
>>
>
>is that you aren't checking that what comes between the two dollar signs
>looks like empty-or-an-identifier.  The check for
>next-char-isn't-a-digit is part of that but not the only part.
>
>


Well, I think the right way to do a full check would be with a regex,
which I had hoped to avoid. However, I will now try to get one working
and to address your other concerns.

Thanks for the comments.

cheers

andrew


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

Предыдущее
От: "Alex J. Avriette"
Дата:
Сообщение: Re: RFC: Very large scale postgres support
Следующее
От: Neil Conway
Дата:
Сообщение: Re: psql variables