Received: from localhost (maia-2.hub.org [200.46.204.187]) by postgresql.org (Postfix) with ESMTP id A21F89FA2CA for ; Thu, 30 Nov 2006 21:07:57 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.187]) (amavisd-new, port 10024) with ESMTP id 52778-10 for ; Thu, 30 Nov 2006 21:07:48 -0400 (AST) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.4 Received: from nf-out-0910.google.com (nf-out-0910.google.com [64.233.182.191]) by postgresql.org (Postfix) with ESMTP id DC6C19FA17A for ; Thu, 30 Nov 2006 21:07:52 -0400 (AST) Received: by nf-out-0910.google.com with SMTP id x4so3499356nfb for ; Thu, 30 Nov 2006 17:07:51 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:sender:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references:x-google-sender-auth; b=BoWn2lYxgkl9uadcFxCO4Ok1uwib2m6boQ/B8a5xSJcy3qiIkU/8dIXnSRbDc+MXtoY3aphlBvQIVSbrJSzHWyD9wpRZDKzNpOAjpOmg8dQ2wiiDuaKjbkmvBTki+1fIe6Ak1JG6WE/reXlvFy3VQZQxwH9SA4gLJn2c93cbPa0= Received: by 10.82.129.8 with SMTP id b8mr946635bud.1164935270761; Thu, 30 Nov 2006 17:07:50 -0800 (PST) Received: by 10.82.118.19 with HTTP; Thu, 30 Nov 2006 17:07:50 -0800 (PST) Message-ID: <74e15baa0611301707m413453ddhc3b7584c4f5dbf3a@mail.gmail.com> Date: Thu, 30 Nov 2006 20:07:50 -0500 From: "Aaron Mulder" To: pgsql-jdbc@postgresql.org Subject: Re: Backup with Java In-Reply-To: <456afd7a.330.e42.37531057@webh5.fe.aruba.it> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <456afd7a.330.e42.37531057@webh5.fe.aruba.it> X-Google-Sender-Auth: ca2bd1a0c10abc6d X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200611/190 X-Sequence-Number: 16232 Seems like a hybrid approach may be the most practical. If you dump the DDL rarely (or whenever it changes) with pg_dump or a similar DB-specific tool, then you could probably generate a frequent data backup fairly easily with pure JDBC code. The only trick on the restore would be to do it in an order consistent with the keys, and again, you ought to be able to determine that via JDBC (or perhaps determine that it's not possible, in which case maybe you manually insert some statements to suspend RI during the import or whatever). Thanks, Aaron On 11/27/06, tommaso.taruffi@ricesoft.it wrote: > Hello, > I have a question about how I can make a database backup > with Java. I have made a class Connection.java that connect > my application with Postgresql Database. I would make a > function in this class for backup the state of the database. > Anyone can help me? > > Thanks! > Dr. Tommaso Taruffi > > ---------------------------(end of broadcast)--------------------------- > TIP 7: You can help support the PostgreSQL project by donating at > > http://www.postgresql.org/about/donate >