1

I have a database named housing that I want to export. However, everytime i export it, it generates a blank dump file. I cannot identify what I've been doing wrong. Please help.

I'm trying using phppgadmin, I clicked export, selected SQL, structure and data as format and then download, but the dump file generated is always blank.

I think I know now what the problem is, I have different two versions of postgreSQL installed on my laptop. postgreSQL version 9.3.6 that comes with Bitnami WAPPstack) and I forgot that I had previously installed postgreSQL version 9.4.1 too. I get a pg_dump aborting because of server version mismatch. How do I fix this? Can I just simply uninstall the one that is not with the Bitnami WAPPStack? Or will my database be deleted along with it? I'm sorry I know nothing . :(

user2332475
  • 43
  • 1
  • 6
  • Are you trying to export it via terminal or phppgadmin or pgadmin3. Also please share the code too. – Nandakumar V Jun 02 '15 at 11:56
  • I'm trying using phppgadmin, I clicked export, selected SQL, structure and data as format and then download, but the dump file generated is always blank. @NandakumarV – user2332475 Jun 02 '15 at 13:11
  • From which page you have clicked the export link? You should click export from the page with list all tables. – Nandakumar V Jun 02 '15 at 15:35
  • Dumping of complex table and schema names on Windows is not supported. --This is now what the dump file is saying – user2332475 Jun 02 '15 at 16:13
  • Ahh... windows... I also had the same error long ago, but forgot how i solved it.. Can you check this page http://phppgadmin.sourceforge.net/doku.php?id=faq#questions_on_dumps and see if anything works :) – Nandakumar V Jun 02 '15 at 16:36
  • I think I know now what the problem is, I have different two versions of postgreSQL installed on my laptop. postgreSQL version 9.3.6 that comes with Bitnami WAPPstack) and I forgot that I had previously installed postgreSQL version 9.4.1 too. I get a pg_dump aborting because of server version mismatch. How do I fix this? Can I just simply uninstall the one that is not with the Bitnami WAPPStack? Or will my database be deleted along with it? I'm sorry I know nothing . :( @NandakumarV – user2332475 Jun 03 '15 at 05:03

1 Answers1

1

http://www.expertphp.in/article/postgres-phppgadmin-problem-empty-sql-dump-after-export

https://www.youtube.com/watch?v=L4W_6jnBXk0

Short: In /usr/share/phppgadmin/dbexport.php.

Change the line from : $cmd = $exe . " -i"; To `$cmd = $exe;

and then change passthru($cmd); To echo passthru($cmd);

Phani Kumar M
  • 4,564
  • 1
  • 14
  • 26