[odb-users] Error: Relation "schema_version" already exists

Arnaud Kapp arnaud.kapp at islog.com
Tue Sep 13 05:39:50 EDT 2016


Hello Boris,

Oh, that makes sense now. Indeed all works great with
--pgsql-server-version 9.1

Thank you very much !

On 09/12/2016 05:06 PM, Boris Kolpackov wrote:
> Hi Arnaud,
>
> Arnaud Kapp <arnaud.kapp at islog.com> writes:
>
>> The problem is, when targeting Postgre, an exception is thrown
>> when creating the second schema. The first one gets created ok,
>> then `42P07: ERROR:  relation "schema_version" already exists` is
>> thrown.
>
> PostgreSQL prior to 9.1 doesn't have support for IF NOT EXISTS clause
> in CREATE TABLE. As a result, if targeting any PG version ODB can't
> do much about it. You can tell ODB you are using 9.1 or later with:
>
> --pgsql-server-version 9.1
>
> Boris
>

-- 
Best regards / Cordialement,

Arnaud KAPP
13, rue du général de Castelnau
67000 Strasbourg
FRANCE
http://www.islog.com



More information about the odb-users mailing list