Re: pg_restore cannot restore index - Mailing list pgsql-sql

From Jie Liang
Subject Re: pg_restore cannot restore index
Date
Msg-id 7C760DAA511DC74B99E7D22189F786F101BF2115@MAIL01.stbernard.com
Whole thread Raw
In response to pg_restore cannot restore index  (Jie Liang <jie@stbernard.com>)
List pgsql-sql


Another possible bug:
pg_restore -i "\"indexname\"" -d mydb mydumpfile
msg:
pg_restore: connecting to database for restore
pg_restore: creating FUNCTION "plpgsql_call_handler" ()
pg_restore: [archiver (db)] could not execute query: ERROR:  function
plpgsql_call_handler already exists with same argument types
pg_restore: *** aborted because of error

I read the pg_restore.c source code, I found:
#ifdef HAVE_GETOPT_LONG       struct option cmdopts[] = {               {"clean", 0, NULL, 'c'},
{"create",0, NULL, 'C'},               {"data-only", 0, NULL, 'a'},               {"dbname", 1, NULL, 'd'},
 {"file", 1, NULL, 'f'},               {"format", 1, NULL, 'F'},               {"function", 1, NULL, 'P'},
{"host", 1, NULL, 'h'},               {"ignore-version", 0, NULL, 'i'},               {"index", 1, NULL, 'I'},
 
So, -i may be mapped wrong, however, -I is illegal option.

Thanks!


Jie Liang



pgsql-sql by date:

Previous
From: Jie Liang
Date:
Subject: pg_restore cannot restore index
Next
From: Bruce Momjian
Date:
Subject: Re: pg_restore cannot restore index