Re: how to emit line number in a function?

Поиск
Список
Период
Сортировка
От Bricklen Anderson
Тема Re: how to emit line number in a function?
Дата
Msg-id 436A4807.7080308@PresiNET.com
обсуждение исходный текст
Ответ на Re: how to emit line number in a function?  (Richard Huxton <dev@archonet.com>)
Ответы Re: how to emit line number in a function?  ("Jim C. Nasby" <jnasby@pervasive.com>)
Список pgsql-general
Richard Huxton wrote:
> Bricklen Anderson wrote:
>
>>I couldn't find any useful references in the docs or archives for emitting the
>>line number of a plpgsql function (in a RAISE statement). I'd like to use it for
>>debugging some complex functions.
>>Does anyone have any tips on where to look, or an example of this?
>
>
> I don't think you can do so yourself. However, recent versions of PG
> should display the line number of a RAISE NOTICE or similar if you have
> the error verbosity high enough.
>
Okay, thanks for the head's up.
Is there any other way to get the current line number, for example, an inline
function call to elog(?) or something? It's not a huge deal, but it would be
useful for debugging and timings.

--
_______________________________

This e-mail may be privileged and/or confidential, and the sender does
not waive any related rights and obligations. Any distribution, use or
copying of this e-mail or the information it contains by other than an
intended recipient is unauthorized. If you received this e-mail in
error, please advise me (by return e-mail or otherwise) immediately.
_______________________________

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

Предыдущее
От: Richard Huxton
Дата:
Сообщение: Re: Querying for related tables
Следующее
От: Csaba Nagy
Дата:
Сообщение: Re: Changing ids conflicting with serial values?