Received: from bush.rutgersinsurance.com (rutgersinsurance.com [38.138.71.194]) by mail.postgresql.org (8.11.1/8.11.1) with ESMTP id eA1Ge1l73534 for ; Wed, 1 Nov 2000 11:40:01 -0500 (EST) (envelope-from aalang@rutgersinsurance.com) Received: from 6014cwpza006 ([10.10.10.51]) by bush.rutgersinsurance.com (8.9.3/8.9.3) with SMTP id LAA04835 for ; Wed, 1 Nov 2000 11:45:06 -0500 Message-ID: <018d01c04422$b6eaec80$330a0a0a@6014cwpza006> From: "Adam Lang" To: References: <20001101150721.15601.qmail@web9503.mail.yahoo.com> Subject: Re: listing databases Date: Wed, 1 Nov 2000 11:42:24 -0500 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.50.4133.2400 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400 X-Archive-Number: 200011/9 X-Sequence-Number: 17 Ah, gotcha. That's good to know. Adam Lang Systems Engineer Rutgers Casualty Insurance Company ----- Original Message ----- From: "Dan Wilson" To: "Adam Lang" ; Sent: Wednesday, November 01, 2000 10:07 AM Subject: Re: [PHP] listing databases > I connect using the default database which is usually > template1. But you can access the system tables from > a connection into any database. > > -Dan > > --- Adam Lang wrote: > > So you just connect to the database using username, > > password, host, and > > port? Don't use a dbname in the connection string? > > > > Adam Lang > > Systems Engineer > > Rutgers Casualty Insurance Company > > ----- Original Message ----- > > From: "Dan Wilson" > > To: "magnus" ; > > > > Sent: Wednesday, November 01, 2000 10:38 AM > > Subject: Re: [PHP] listing databases > > > > > > > Databases: > > > > > > SELECT datname FROM pg_databases > > > > > > Tables: > > > > > > SELECT tablename FROM pg_tables WHERE tablename > > NOT LIKE 'pg%' > > > > > > The "NOT LIKE 'pg%'" filters out the system > > tables. > > > > > > If you are interested in learning more about the > > system tables, you can > > > download my phpPgAdmin > > (http://www.phpwizard.net/projects/phpPgAdmin) and > > > view the source code. I have to use the system > > tables for almost > > > everything. If you do not want to download it, > > you can check out the > > source > > > code through the snapshot page > > (http://pgdemo.acucore.com/snapshot). > > > > > > -Dan Wilson > > > > > > > > > ----- Original Message ----- > > > From: "magnus" > > > To: > > > Sent: Wednesday, November 01, 2000 7:02 AM > > > Subject: [PHP] listing databases > > > > > > > > > > Hello, > > > > Can anyone tell me how to list (1.) databases > > and (2.) tables in a > > > > database using php? > > > > Thanks, > > > > Magnus Lawrie > > > > > __________________________________________________ > Do You Yahoo!? > >From homework help to love advice, Yahoo! Experts has your answer. > http://experts.yahoo.com/