X-Original-To: pgsql-php-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [64.117.224.130]) by svr1.postgresql.org (Postfix) with ESMTP id 45E84D1C964 for ; Wed, 23 Jul 2003 14:32:22 +0000 (GMT) Received: from svr1.postgresql.org ([64.117.224.193]) by localhost (neptune.hub.org [64.117.224.130]) (amavisd-new, port 10024) with ESMTP id 33603-01 for ; Wed, 23 Jul 2003 11:31:32 -0300 (ADT) Received: from mailav.tor1.inquent.com (mail.inquent.com [216.208.117.106]) by svr1.postgresql.org (Postfix) with ESMTP id 73856D1C96C for ; Wed, 23 Jul 2003 11:32:13 -0300 (ADT) Received: from localhost (localhost [127.0.0.1]) by mailav.tor1.inquent.com (Postfix) with ESMTP id E080110258; Wed, 23 Jul 2003 10:25:09 -0400 (EDT) Received: from [10.0.2.10] (unknown [10.0.2.10]) by mailav.tor1.inquent.com (Postfix) with ESMTP id 0559A10248; Wed, 23 Jul 2003 10:25:07 -0400 (EDT) Subject: Re: How to Determine Number of connected users From: Rod Taylor To: Andrei Verovski Cc: pgsql-php@postgresql.org In-Reply-To: References: Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="=-AkxCPJ1nAHKm9pTosUVG" Message-Id: <1058970772.48936.13.camel@jester> Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.4.3 Date: 23 Jul 2003 10:32:53 -0400 X-Virus-Scanned: by AMaViS perl-11 X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200307/42 X-Sequence-Number: 2154 --=-AkxCPJ1nAHKm9pTosUVG Content-Type: text/plain Content-Transfer-Encoding: quoted-printable On Wed, 2003-07-23 at 10:27, Andrei Verovski wrote: > Hi, >=20 > Is it possible to determine number of connected users to certain=20 > PostgreSQL database from within PHP script? select * from pg_stat_activity; Add the appropriate where clause for whatever you are trying to restrict by. --=-AkxCPJ1nAHKm9pTosUVG Content-Type: application/pgp-signature; name=signature.asc Content-Description: This is a digitally signed message part -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.2 (FreeBSD) iD8DBQA/HpyU6DETLow6vwwRArjjAJwKJGwqXAguRIdSqcFtQxWbn0ZkeACfeeBg ctlOKg0t/MXYRZabiRL6m5E= =nx2R -----END PGP SIGNATURE----- --=-AkxCPJ1nAHKm9pTosUVG--