X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 2CD495E46C2 for ; Tue, 31 Aug 2004 04:55:34 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 02376-09 for ; Tue, 31 Aug 2004 07:55:22 +0000 (GMT) Received: from mpls-qmqp-01.inet.qwest.net (mpls-qmqp-01.inet.qwest.net [63.231.195.112]) by svr1.postgresql.org (Postfix) with SMTP id C092A5E3631 for ; Tue, 31 Aug 2004 04:55:26 -0300 (ADT) Received: (qmail 69053 invoked by uid 0); 31 Aug 2004 07:55:27 -0000 Received: from unknown (63.231.195.1) by mpls-qmqp-01.inet.qwest.net with QMQP; 31 Aug 2004 07:55:27 -0000 Received: from 63-227-127-37.dnvr.qwest.net (HELO ?10.0.0.2?) (63.227.127.37) by mpls-pop-01.inet.qwest.net with SMTP; 31 Aug 2004 07:55:26 -0000 Date: Tue, 31 Aug 2004 01:57:04 -0600 Message-Id: <1093939024.5493.62.camel@localhost.localdomain> From: "Scott Marlowe" To: "Pradeepkumar, Pyatalo (IE10)" Cc: pgsql-admin@postgresql.org Subject: Re: help on automatically running sql files In-Reply-To: <77ED2BF75D59D1439F90412CC5B1097410F1EE62@ie10-sahara.hiso.honeywell.com> References: <77ED2BF75D59D1439F90412CC5B1097410F1EE62@ie10-sahara.hiso.honeywell.com> Content-Type: text/plain Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.4.6 (1.4.6-2) Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200408/305 X-Sequence-Number: 14700 On Tue, 2004-08-31 at 01:33, Pradeepkumar, Pyatalo (IE10) wrote: > Hi all, > For the project that I am working on , we are using Postgresql 7.4.3 on > Linux 7.2. We have all the database tables,triggers and stored procedures as > seperate .sql files which we want to ship as part of our software. Now when > the user installs our software, we need to check if postmaster service is > running or not and if it is running, then we have to run the sql files > automatically. Can anyone help me out on how to run the .sql files > automatically. Something like psql dbname