RE: CREATE USER - Mailing list pgsql-general

From Hiroshi Inoue
Subject RE: CREATE USER
Date
Msg-id 000701bfcb8e$74fd11c0$2801007e@tpf.co.jp
Whole thread Raw
In response to Re: CREATE USER  (Thomas Lockhart <lockhart@alumni.caltech.edu>)
Responses Re: CREATE USER  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-general
> -----Original Message-----
> From: pgsql-general-owner@hub.org [mailto:pgsql-general-owner@hub.org]On
> Behalf Of Thomas Lockhart
>
> > I have to create users via an ODBC connection, but I get this error:
> >   CREATE USER: may not be called in a transaction block
> > With psql I have no problems. Any body knows what is happening?
>
> Yeah. There are too many transaction block wrappers (BEGIN/COMMIT
> statements) in the ODBC driver. I'm not sure if we have patches for it
> yet...
>

Currently the following command sequence isn't allowed.

begin;
create user ...
commit;

This wouldn't be good for odbc/jdbc/ecpg etc.

How about starting new transaction automatically after committing
"create user ..." at backend side if "create user" is the first command
of the transaction ?

Regards.

Hiroshi Inoue
Inoue@tpf.co.jp

pgsql-general by date:

Previous
From: Thomas Lockhart
Date:
Subject: Re: CREATE USER
Next
From: Louis-David Mitterrand
Date:
Subject: Re: [HACKERS] Oft Ask: How to contribute to PostgreSQL?