From rong.xie@stud.tu-muenchen.de Mon Jun 8 11:23:36 2026 X-Original-To: pgadmin-hackers@postgresql.org Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id 2E22C474E5C; Wed, 12 Feb 2003 05:44:17 -0500 (EST) Received: from mailrelay2.lrz-muenchen.de (mailrelay2.lrz-muenchen.de [129.187.254.102]) by postgresql.org (Postfix) with ESMTP id 2C107474E44; Wed, 12 Feb 2003 05:44:16 -0500 (EST) Received: from [138.245.10.1] by mailout.lrz-muenchen.de; Wed, 12 Feb 2003 11:44:15 +0100 Message-Id: <000801c2d283$564c39a0$d2e0f48a@ips64m> From: "XIE, Rong" To: <"Undisclosed-Recipient:;"@postgresql.org> Subject: help me!! Date: Wed, 12 Feb 2003 11:41:44 +0100 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_0005_01C2D28B.B7CBD070" X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.00.2919.6700 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2919.6700 X-Virus-Scanned: by AMaViS new-20020517 X-Archive-Number: 200302/26 X-Sequence-Number: 754 This is a multi-part message in MIME format. ------=_NextPart_000_0005_01C2D28B.B7CBD070 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Hello,=20 My name is rong xie. I am a Student at TU-Munich. I have a question to Postgresql an Linux.=20 e.g: for IBM DB2: I can write a test.sql file. --test.sql connect to database1; set schema xie; select * from table1; insert table1 value('rong','xie',22); select * from table1; terminate; Then I can execute the file "test.sql" in terminal. db2 -tvf test.sql In mysql: I can execute it so. mysql > test.sql How can I execute it in Postgresql? is there similar command in linux for Postgresql? Thank you very mach! Best wish! rong xie=20 ------=_NextPart_000_0005_01C2D28B.B7CBD070 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
Hello,
 
My name is rong xie. I am a Student at=20 TU-Munich.
I have a question to Postgresql an Linux.= =20
e.g:
for IBM DB2: I can write a test.sql=20 file.
 
--test.sql
connect to database1;
set schema xie;
select * from table1;
insert table1 value('rong','xie',22);
select * from table1;
terminate;
 
Then I can execute the file "test.sql" in= =20 terminal.
db2 -tvf test.sql
 
In mysql: I can execute it so.
mysql > test.sql
 
How can I execute it in Postgresql?=
is there similar command in linux for=20 Postgresql?
 
Thank you very mach!
 
Best wish!
 
rong xie
------=_NextPart_000_0005_01C2D28B.B7CBD070-- From aledes@telefonica.net Mon Jun 8 11:23:37 2026 X-Original-To: pgsql-general@postgresql.org Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id D381D475DAD for ; Thu, 13 Feb 2003 14:25:34 -0500 (EST) Received: from tnetsmtp2.mail.isp (stress.telefonica.net [213.4.129.135]) by postgresql.org (Postfix) with ESMTP id 9AB94475E31 for ; Thu, 13 Feb 2003 14:25:04 -0500 (EST) Received: from maradis ([217.127.98.52]) by tnetsmtp2.mail.isp (terra.es) with ESMTP id HA9HXR00.OIF; Thu, 13 Feb 2003 20:25:03 +0100 Message-ID: <003901c2d395$29652ec0$02001aac@maradis> From: "Andres Ledesma" To: "rx" Cc: References: <000801c2d283$564c39a0$d2e0f48a@ips64m> <000f01c2d2e4$a8cae1c0$02001aac@maradis> <002901c2d360$8c5cac40$16e1f48a@IPSM7N> Subject: Re: [ADMIN] help me!! Date: Thu, 13 Feb 2003 20:21:50 +0100 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_0036_01C2D39D.8A8C4550" X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2600.0000 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000 X-Virus-Scanned: by AMaViS new-20020517 X-Archive-Number: 200302/729 X-Sequence-Number: 37483 This is a multi-part message in MIME format. ------=_NextPart_000_0036_01C2D39D.8A8C4550 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable hi rong... well...is the postmaster running ?=20 there are a couple of postintallation steps ... first, you must create and prepare the data files. lets assume your pgSQL is installed on /usr/local/pgsql, right ?=20 1 . make dir where your data files are going to live, say data root# mkdir /usr/local/pgsql/data 2 . lets make user postgres the owner of this dir root# chown postgres /usr/local/pgsql/data=20=20=20=20 3 . let postgres init dababase on this dir root# su postgres postgres# /usr/local/pgsql/bin/initdb -D /usr/local/pgsql/data 4 . start the postmaster.. set the environment var PGDATA=3D/usr/local/pgsql/data postgres# /usr/local/pgsql/bin/postmaster -i -i allows tcp connections to the db.=20 5 .start the client=20 postgres# /usr/local/pgsql/bin/psql There is are various front end GUI's to postgres..one I use is pgAc= cess-- go to their page and lurk a bit ..=20 If you don't have the postgresql docs, you should take it on the postgres= ql.org site because there are a lot of options to postgresql be compiled wi= th depending on further use you are going to do..to conect via Java, C++..= . and any way...printing this docs you'll find most of your answers faster.= There are the admin, programmer, user...guides..and a small tutorial.. Good luck .. and best regards, Andrew ------=_NextPart_000_0036_01C2D39D.8A8C4550 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
hi rong...
 
well...is the postmaster running ? =
 
there are a couple of postintallation step= s=20 ...
 
    first, you must create = and=20 prepare the data files.
    lets assume your pgSQL = is=20 installed on /usr/local/pgsql, right ?
 
    1 . make dir where your= data=20 files are going to live, say data
        root# mkdir=20 /usr/local/pgsql/data
 
    2 . lets make user post= gres the=20 owner of this dir
        root# chown p= ostgres=20 /usr/local/pgsql/data    
 
    3 . let postgres i= nit=20 dababase on this dir
        root= # su=20 postgres
        postgres#=20 /usr/local/pgsql/bin/initdb -D  /usr/local/pgsql/data
 
    4 . start the=20 postmaster..
        set = the=20 environment var PGDATA=3D/usr/local/pgsql/data
        postgres#=20 /usr/local/pgsql/bin/postmaster -i
 
        -i allows tcp  connections = to=20 the db.
 
    5 .start the client 
        postgres#=20 /usr/local/pgsql/bin/psql
 
        There is are various front = end=20 GUI's to postgres..one I use is pgAccess-- go to their page and lurk a bit = ..=20
 
  If you don't have the postgres= ql docs,=20 you should take it on the postgresql.org site because there are a lot of op= tions=20 to postgresql be compiled with depending on further use you are going to do= ..to=20 conect via  Java, C++... and any way...printing this docs you'll = find=20 most of your answers faster. There are the admin, programmer, user...guides= ..and=20 a small tutorial..
 
    Good luck .. and best regards,
 
Andrew
 
------=_NextPart_000_0036_01C2D39D.8A8C4550--