From: | "Joe Shevland" <jshevland(at)j-elite(dot)com> |
---|---|
To: | <vernonw(at)gatewaytech(dot)com>, <pgsql-jdbc(at)postgresql(dot)org> |
Subject: | Re: Utility for creating tables, inserting data through Ant |
Date: | 2002-04-23 00:21:54 |
Message-ID: | HEECIHEEJDBMCCGMGIOBEEFACHAA.jshevland@j-elite.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-jdbc |
Hi Vernon,
I'm actually working on a PGTask Ant task as we speak that does this... there is the generic 'SQL' Ant task that can process SQL from a file too though. I think I should be able to simply extend the SQL ant task class, if so it'll only be to add any PG specific behaviour (maybe md5 connections if it can't already be done in the SQL task, LO import etc), or failing that there's a psql.java example in the distribution that might be a starting point.
In the interim, if you have access to the psql command line tool, you can use the Ant exec task to pump the contents of a file to it also on *nix, or Windows with Cygwin installed.
Cheers,
Joe
> -----Original Message-----
> From: pgsql-jdbc-owner(at)postgresql(dot)org
> [mailto:pgsql-jdbc-owner(at)postgresql(dot)org]On Behalf Of Vernon Wu
> Sent: Monday, 22 April 2002 10:19
> To: pgsql-jdbc(at)postgresql(dot)org
> Subject: [JDBC] Utility for creating tables, inserting data through Ant
>
>
> Hi,
>
> Is a utility available in the PostGreSQL jdbc so that we can run
> Ant to deploy an application?
>
> The build.xml file for Ant is something like
>
> <target name="db-create-table" depends="init">
> <java classname="COM.postgresql.tools. ..." fork="yes" >
> <jvmarg line="${postgres-jvmargs}" />
> <arg value="${sql}/create-table.sql" />
> <classpath path="${postgres-path}" />
> </java>
> </target>
>
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 4: Don't 'kill -9' the postmaster
>
From | Date | Subject | |
---|---|---|---|
Next Message | sathyanarayanan_s | 2002-04-23 02:41:53 | unsubscribe |
Previous Message | Dave | 2002-04-22 21:05:42 | help |