pg.ddx.io  pgsql-php@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Dawid Ferenczy <ferenczy@volny.cz>
To: pgsql-php@postgresql.org
Subject: PgSQL error codes in PHP
Date: Fri, 12 Nov 2004 14:01:11 +0100
Message-ID: <4194B417.9020206@volny.cz> (raw)

Hi,

   I need help, please - I tried Google, some specialized mailinglist
and I got no result for a week. I would like to determine PgSQL error
codes in PHP after executing a query, but I found functions for getting
error messages only which I found not usable (messages are often
localised and so on). On PHP manual pages is for that reason some patch,
but only for PHP 4.x and with broken link ;) I need solution in PHP 5.

  For example:

  'CREATE TABLE xxx;'

  If table already exists, PgSQL return error message "Relation xxx
already exists" or "Relace xxx jiz existuje" in czech language and (not
in UTF-8 coding ;)

  So now, I know that some error occurs but I cannot determine cause :(
(compare error messages is nonsense).

  If I'll not find relevant solution, I'm going to write this function
in PgSQL extension (oh my God!!! [I'm atheist ;) ])

  Sorry for my english, it isn't my strong side, if you want I'll
welcome some language corrections ;)

  Thanx a lot, you are my last chance before I'll go to write my own
implementation...

-- 
 Dawid Ferenczy
 http://xcoder.jinak.cz
 ICQ: 85997864




view thread (3+ messages)  latest in thread

Message-ID: <4194B417.9020206@volny.cz>
Permalink:  ../4194B417.9020206@volny.cz/
Also on:    postgresql.org/message-id/4194B417.9020206@volny.cz

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-php@postgresql.org
  Cc: ferenczy@volny.cz
  Subject: Re: PgSQL error codes in PHP
  In-Reply-To: <4194B417.9020206@volny.cz>
  References: <4194B417.9020206@volny.cz>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox