Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mEHK8-0007ru-PS for pgsql-general@arkaria.postgresql.org; Thu, 12 Aug 2021 20:29:09 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1mEHK7-0008EO-Kd for pgsql-general@arkaria.postgresql.org; Thu, 12 Aug 2021 20:29:07 +0000 Received: from makus.postgresql.org ([72.32.157.229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mEHK6-0008EG-5L for pgsql-general@lists.postgresql.org; Thu, 12 Aug 2021 20:29:07 +0000 Received: from wout3-smtp.messagingengine.com ([64.147.123.19]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mEHK0-0003LN-4E for pgsql-general@lists.postgresql.org; Thu, 12 Aug 2021 20:29:05 +0000 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.west.internal (Postfix) with ESMTP id E3E9B3200927; Thu, 12 Aug 2021 16:28:57 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute4.internal (MEProxy); Thu, 12 Aug 2021 16:28:58 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aklaver.com; h= subject:to:references:from:message-id:date:mime-version :in-reply-to:content-type:content-transfer-encoding; s=fm3; bh=w 29GrCdc6YSJb7+imfWamYQhA0Pexc9khjAHZEtSQUc=; b=DUWO3fPdRmTuekp0v twncffq3eVagLjTJcDVum4HQcCRnP9IMydWQjH9MgiV3FNeaCIYDp68ILucuwII5 CveJgHCSRsjWTPzP/UgZDElW5K5hMkm80ikGqNlWvJQArQx+PziPF3GD6rA5y5St oGNdQf0BlvyUDvooOXYCT1b02cevLafSv0RTCrt1CTR1HJxpVrbiJpgY2Bei3pyb Ao8Wl5pYGhKEk9yyazNpDd/8hclug7BTJ8Mz/8j0l7DANeTyJSyTrFO6rJNxxMqj IHdZfVZBH4vHC6Xxy/zfF+feiOA7AXNr3b1RAXmDiDq1pjvtGpEdfrd+9+MXS+Ql HSA9Q== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm3; bh=w29GrCdc6YSJb7+imfWamYQhA0Pexc9khjAHZEtSQ Uc=; b=HcOdbqqnXHCvcgnbqnCR2sAzAIb9dh1sa8jErZvFgRhM7zEwoedAbNFDb Ke3IobqTQf1iKZB0icDBGM1PFqOH6aic6ht/ggLIkVAZImEVVjluldRP4seNhLhl p0l36mdhx8HnGNkAFpFF1679pVnnE4X394LOOBsqKtLWIQJ6RWJYeK8jPetla3q+ /vsL/OfizqgRsU50ID+XrbP3eJPtMTZeGrdCADyHtPrvIr5/ikPzS2Y9vtVN+Bqm 0Hh30OxVNLzZnoWx4Zhv39zyKytSNV8Tj0g8dSp80huksEzQra0r+X5T7YSUvwhj U1vQU2b3Sx2iYhsyx/KiNW8ZrTfRA== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvtddrkeefgddugeelucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepuffvfhfhkffffgggjggtgfesthekredttdefjeenucfhrhhomheptegurhhi rghnucfmlhgrvhgvrhcuoegrughrihgrnhdrkhhlrghvvghrsegrkhhlrghvvghrrdgtoh hmqeenucggtffrrghtthgvrhhnpeduudefjeetveffhefgudehtdfhvdetkeeiueehfeev veduteekleeuheegudehhfenucffohhmrghinhepphhoshhtghhrvghsqhhlrdhorhhgne cuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomheprggurhhi rghnrdhklhgrvhgvrhesrghklhgrvhgvrhdrtghomh X-ME-Proxy: Received: by mail.messagingengine.com (Postfix) with ESMTPA; Thu, 12 Aug 2021 16:28:56 -0400 (EDT) Subject: Re: log_statement GUC parameter To: Mladen Gogala , pgsql-general References: <510207d8-8895-c3cb-e0a1-55135e4ce4f7@gmail.com> From: Adrian Klaver Message-ID: Date: Thu, 12 Aug 2021 13:28:55 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.13.0 MIME-Version: 1.0 In-Reply-To: <510207d8-8895-c3cb-e0a1-55135e4ce4f7@gmail.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 8/12/21 1:19 PM, Mladen Gogala wrote: > Hi! > > The idea is to log all statements by the particular user, not by > everybody. The user in question uses Weblogic 12.2.1.4  and creates a > connection pool so I need to find out which statements are the longest > running ones and make them perform. Would pg_stat_statements work for you?: https://www.postgresql.org/docs/current/pgstatstatements.html > > Regards > -- Adrian Klaver adrian.klaver@aklaver.com