Re: Help With Database Backup

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 





> Subject: Re: Help With Database Backup
> From: andy-lists@xxxxxxxxxxxxxx
> Date: Wed, 30 Sep 2009 22:24:27 +0100
> CC: pgsql-admin@xxxxxxxxxxxxxx
> To: chaluwa@xxxxxxxxx
>
> Hi,
>
> >
> > Hello there, I am new to PostgreSQL, succeded in running a little
> > database on
> > my dev. machine and now I am having problems exporting the local
> > database to
> > the one I want to use on my site online. I am getting errors when I
> > try to
> > run the SQL online with phpPgAdmin.
>
> What errors are you getting? It's impossible to give you any help
> unless you can provide a bit more information.
>
> >
> > I exported / backup the local database using pgAmin, I choose the
> > PLAIN
> > format and then selected the No Owner option as well as the Schema
> > Only
> > option (how canI export schema and data at once).

as postgresql user
pg_dump dbname > anyname.out
copy the .out file to your target box

in your target box as postgresql user

createdb dbname
psql dbname -f anyname.out



>
> I believe if you don't select "schema only" you get schema and data.
>
> Regards,
> Andy
>
> --
> Sent via pgsql-admin mailing list (pgsql-admin@xxxxxxxxxxxxxx)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-admin

[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux