Received: from malur.postgresql.org ([2a02:16a8:dc51::56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1g0Xch-0000DZ-Kg for pgsql-performance@arkaria.postgresql.org; Thu, 13 Sep 2018 19:49:55 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1g0Xcd-0006Z6-AH for pgsql-performance@arkaria.postgresql.org; Thu, 13 Sep 2018 19:49:51 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1g0Xcd-0006Yz-0V for pgsql-performance@lists.postgresql.org; Thu, 13 Sep 2018 19:49:51 +0000 Received: from mail-it0-x229.google.com ([2607:f8b0:4001:c0b::229]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1g0XcV-0002Da-8Z for pgsql-performance@lists.postgresql.org; Thu, 13 Sep 2018 19:49:50 +0000 Received: by mail-it0-x229.google.com with SMTP id h20-v6so9334646itf.2 for ; Thu, 13 Sep 2018 12:49:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=message-id:mime-version:to:from:subject:date:importance; bh=4DemBil00UHZjq9TFRMssNvFN5IEK6f6U/LTI6Bmwg0=; b=ckv4kzCkciaEhkNRNhvWPI1roPwIiwTRitxquJKosKbbtEBBmC+D01mVRSDT5thZ+p HolFpJP7xzSgzHkR9u6vz1fSqlqNb4qQKPUSofDcrYRqPcG187qjVUTwdujlUIBh8Hhh Ovr7Tjr9TTRsZSf/kaWAV+0o/vZPtER+tXC1IIH02xofH/Sa+HQTCF1FvXKdwENjvX4Y 13nA2BiqJP/OtYfrmpQbd2+6L0eSTFki586lLhHhv3+IO691qAG4Hb9lmhsf7mpwnWks mIqEDXvdfyRwlNQTAwS1nuv7a/Oy3wM4dC60sVP1DTp2U0SgVufalntPYAYUkpW2j/B+ 9Ocg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:mime-version:to:from:subject:date :importance; bh=4DemBil00UHZjq9TFRMssNvFN5IEK6f6U/LTI6Bmwg0=; b=GsA6MC0B9U/pEIaSk7+3a1hnTwsVL81l72YM+8RS/qZJx39vUr6Al9Rv4opRAMyaOg sII5yNo8OQkezVID3okrSvONQkmtU2KNo0HxudHZ71KVtvKdykHVeGt3hm5fUWfypx3V Hql0TaEArRlKJWq4WmJLhFf1rv951EbpIw/0mBUmuLgTiDZWAn7Ia+EmOB7jDX1/CiYK +ZPEnnVf0zLR0e8im5jdUT4AYPO2cGDMwlZasBowkBxlzOeoFnkw1v/14m9HNKQIgj+y jm+BPx5PNtXt2uDZhFqXSHW9OB44SynX0OTJeBBtsJMLcTn1X9MSMUXAQ4N0uKXZTwLm zsTw== X-Gm-Message-State: APzg51BK4Q0sJ0oJMXUKCIT20clTqq4M9+eaZTI2EmCcW0pO4yA/toMG OyBAjyiUJRrxn76kln4Q9i09rWVYDP8= X-Google-Smtp-Source: ANB0Vda3bs56h3ci3Bid5vG1PbgFwReh7NrpvghIN4jGrz4B9UtsUJcLcpXqiHZexxBWeyPeUGXJ+g== X-Received: by 2002:a24:ec2:: with SMTP id 185-v6mr7610814ite.81.1536868180480; Thu, 13 Sep 2018 12:49:40 -0700 (PDT) Received: from ?IPv6:::ffff:172.25.137.157? ([165.215.94.3]) by smtp.gmail.com with ESMTPSA id l21-v6sm1610337iom.8.2018.09.13.12.49.39 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 13 Sep 2018 12:49:40 -0700 (PDT) Message-ID: <5b9abf54.1c69fb81.8e0e4.9e2d@mx.google.com> MIME-Version: 1.0 To: "pgsql-performance@lists.postgresql.org" From: Fd Habash Subject: How Do You Associate a Query With its Invoking Procedure? Date: Thu, 13 Sep 2018 15:49:41 -0400 Importance: normal X-Priority: 3 Content-Type: multipart/alternative; boundary="_3B1904E3-1EBF-4F75-A511-CFE00E769DA7_" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --_3B1904E3-1EBF-4F75-A511-CFE00E769DA7_ Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" In API function may invoke 10 queries. Ideally, I would like to know what q= ueries are invoked by it and how long each took.=20 I=E2=80=99m using pg_stat_statement. I can see the API function statement, = but how do I deterministically identify all queries invoked by it? ---------------- Thank you --_3B1904E3-1EBF-4F75-A511-CFE00E769DA7_ Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset="utf-8"

In API function may invoke 10 queries. Ideally, I would like to kn= ow what queries are invoked by it and how long each took.

 

I=E2=80=99m using pg_stat= _statement. I can see the API function statement, but how do I deterministi= cally identify all queries invoked by it?

&nbs= p;

 

= ----------------
Thank you

 

=
= --_3B1904E3-1EBF-4F75-A511-CFE00E769DA7_--