Return-Path: Delivered-To: apmail-db-derby-user-archive@www.apache.org Received: (qmail 20502 invoked from network); 9 Jan 2009 04:21:44 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 9 Jan 2009 04:21:44 -0000 Received: (qmail 23345 invoked by uid 500); 9 Jan 2009 04:21:43 -0000 Delivered-To: apmail-db-derby-user-archive@db.apache.org Received: (qmail 23318 invoked by uid 500); 9 Jan 2009 04:21:43 -0000 Mailing-List: contact derby-user-help@db.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: List-Id: Reply-To: "Derby Discussion" Delivered-To: mailing list derby-user@db.apache.org Received: (qmail 23309 invoked by uid 99); 9 Jan 2009 04:21:43 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 08 Jan 2009 20:21:43 -0800 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of jamianb@gmail.com designates 64.233.170.185 as permitted sender) Received: from [64.233.170.185] (HELO rn-out-0910.google.com) (64.233.170.185) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 09 Jan 2009 04:21:33 +0000 Received: by rn-out-0910.google.com with SMTP id j66so6261170rne.20 for ; Thu, 08 Jan 2009 20:21:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:in-reply-to:mime-version:content-type :content-transfer-encoding:content-disposition:references; bh=JldfIazX0/wix54FL8/kXNcFJNZ6h8RBnVy8/08LovA=; b=SxRmtHc5TsVkcFDH4c915xXX0/CWxQn5peSOfbHS9BE9unrn2qefsTO8Dyc6sY/laG gr/xS/N6q2itCImOMD/B/kcmb8W1bdTsFvrPFfEUmXIEojtmT15VuV12XZRCTW2I5pZk gMpROiokeHP2ofdqPKNvpSH+Lu98d8KG+SHgg= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:in-reply-to:mime-version :content-type:content-transfer-encoding:content-disposition :references; b=LMh7gqvKJbdkHE90+cWo6QM48lzjObvDiOYAWFvbNJ/iAFj3N11zcuRsN8JJuAdbV7 bpxUHWtMA/MjRb2pqCzWKDGiYcmc1qaW93ICugjHOlTnCubiBe0aNOehHV7A5H2ABAwM FyxhbTiPKoNSYNmhqMrgNfXS3HAfb7psNgQ/U= Received: by 10.150.219.16 with SMTP id r16mr3314824ybg.102.1231474872700; Thu, 08 Jan 2009 20:21:12 -0800 (PST) Received: by 10.151.135.13 with HTTP; Thu, 8 Jan 2009 20:21:12 -0800 (PST) Message-ID: <2bbc8f530901082021o3b552a28v6d124114dad59721@mail.gmail.com> Date: Fri, 9 Jan 2009 15:21:12 +1100 From: "Damian Carey" To: "Derby Discussion" Subject: Re: Derby SQL diff tool suggestions In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <2bbc8f530901081631y39f3ffb2v732b03678961594b@mail.gmail.com> <2bbc8f530901081727p4054ca18xc80b2cbb5e2c1f96@mail.gmail.com> X-Virus-Checked: Checked by ClamAV on apache.org On Fri, Jan 9, 2009 at 2:59 PM, Dag H. Wanvik wrote: > > As a possible hack for really basic needs, Derby has a tool called > dblook whose text output you could possibly diff, maybe after some > filtering ;-) > > Dag Thanks Dag, As part of my research for moving from Postgres to Derby I have used dblook quite a bit to get the schema as DDL, then using (another Derby tool) "ij" to add the schema to a new derby DB. That is OK for a new empty database, but I'm more concerned about the "update existing database" use case. The equivalent Postgres tool (APGDIFF) takes the two nude schemas and proposes which "ALTER TABLE" etc commands can be used to migrate the existing database. It is far from perfect - but it does give a really good start. My Java skills are 7/10 (an adequate pass), but my SQL skills are 3/10 (I can spell "SQL"), so the tool helps ease the transition. The products use Hibernate - and that both creates the schema, and writes all the SQL for us. Thanks for your reply! -Damian