Re: return value from SQL statement

From: Craig Ringer <craig(at)postnewspapers(dot)com(dot)au>
To: Alain Roger <raf(dot)news(at)gmail(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: return value from SQL statement
Date: 2008-03-25 14:02:59
Message-ID: 47E90613.3020703@postnewspapers.com.au
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Alain Roger wrote:
> Hi,
>
> i have a 'insert into' statement and i would like to know if it fails or
> not.
> i was thinking to check the resturn value from this statement, but how to do
> it ?
>
>
The answer depends entirely on how you're using the database.

ODBC?

JDBC?

Perl DBD?

Python with psycopg?

SQL code read by the psql command?

Also, by "failure", do you mean "encountered an error that terminated
the transaction" or "inserted zero rows" ?

--
Craig Ringer

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Bruce Momjian 2008-03-25 14:44:36 Re: Create user trigger?
Previous Message Alain Roger 2008-03-25 13:30:54 return value from SQL statement