On 03/28/2017 12:51 PM, Rob Sargent wrote:
> On 03/27/2017 04:59 AM, MAJUMDER, SAYAN wrote:
>>
>> Hi,
>>
>> I am new to postgresql and presently we are migrating from sql server
>> to postgresql.
>>
>> We have certain functions in sql server such as
>> ERROR_PROCEDURE(),ERROR_LINE(),ERROR_MESSAGE(). I am unable to find
>> any equivalent
>>
>> functions in postgresql. Kindly help me. Thanks in advance. Its urgent.
>>
>>
>>
>> Thanks and regards,
>>
>> Sayan Majumder.
>>
>>
>>
>> This message contains information that may be privileged or
>> confidential and is the property of the Capgemini Group. It is
>> intended only for the person to whom it is addressed. If you are not
>> the intended recipient, you are not authorized to read, print, retain,
>> copy, disseminate, distribute, or use this message or any part
>> thereof. If you receive this message in error, please notify the
>> sender immediately and delete all copies of this message.
>>
>
> Seems you didn't like the "RAISE" option you were given on Stack
> Overflow. You might explain what those functions do to allow postgres
> people to recognize any potential match.
The SQL Server functions:
https://docs.microsoft.com/en-us/sql/t-sql/functions/error-procedure-transact-sql
which at a quick look seem to be a combination of:
https://www.postgresql.org/docs/9.6/static/plpgsql-control-structures.html#PLPGSQL-ERROR-TRAPPING
and
https://www.postgresql.org/docs/9.6/static/plpgsql-errors-and-messages.html
--
Adrian Klaver
adrian.klaver@aklaver.com