sql - Syntax error when trying to import database from two PostgreSQL databases -


i'm trying export database 1 server , put on using phppgadmin. process this:

  1. select database in server 1 , hit export button
  2. select "data , structure , select option in dropdown "copy"
  3. download
  4. create database of same name in server 2 same name database server 1
  5. select database, open sql pane, , paste sql code downloaded server 1
  6. execute

that's when error:

error:  syntax error @ or near "owned" line 73: alter sequence address_customer_id_seq owned address.cust... 

line 73 in entirety is:

 alter sequence address_customer_id_seq owned address.customer_id; 

i've read here may because i've have different versions of postgre on 2 servers. checked server tech, said that, yes, there issue. upgraded server 2. i'm getting same error however.

any idea going on?

thanks much.

postgresql 8.4 not produce dump restores 8.1, it'll use features , syntax not exist in 8.1.

you might able downgrade running 8.1's pg_dump against 8.4 database, it's dump fail.

downgrading far challenge , may involve hand-editing dump produced 8.4's pg_dump make 8.1-compatible.

8.1 ancient , unsupported; final end-of-life release in november 2010. shouldn't consider using new project or tool, , need planning upgrade.

see the postgresql version policy how different these versions are. can learn more reading [release noteshttp://www.postgresql.org/docs/9.2/static/release.html] versions 8.2.0, 8.3.0 , 8.4.0. important understand application visible behavior changes present in each release; must test applications , may need enable backward compatibility settings.

you should read upgrading postgresql cluster documentation- aware pg_upgrade can not used upgrade version older 8.4.

this less painful if install weren't 7 years out of date.


Comments

Popular posts from this blog

linux - xterm copying to CLIPBOARD using copy-selection causes automatic updating of CLIPBOARD upon mouse selection -

c++ - qgraphicsview horizontal scrolling always has a vertical delta -