Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rydau-00HFhx-1j for pgsql-general@arkaria.postgresql.org; Sun, 21 Apr 2024 20:15:24 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1rydas-00FwtS-Fw for pgsql-general@arkaria.postgresql.org; Sun, 21 Apr 2024 20:15:22 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rydas-00FwtH-5W for pgsql-general@lists.postgresql.org; Sun, 21 Apr 2024 20:15:22 +0000 Received: from mail-qv1-xf34.google.com ([2607:f8b0:4864:20::f34]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1rydao-003xmN-J9 for pgsql-general@lists.postgresql.org; Sun, 21 Apr 2024 20:15:20 +0000 Received: by mail-qv1-xf34.google.com with SMTP id 6a1803df08f44-69b730fc89bso14400836d6.1 for ; Sun, 21 Apr 2024 13:15:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1713730517; x=1714335317; darn=lists.postgresql.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=yhEpFsgveosk8aVqC+mv6nRe6O8lSRIF73LILwNl1oE=; b=X0OfDRpYmem8jviz9mlbxuqkRVHLX4PhjaRAg4R/SaP6vs37GDPrvLzTK40tk/s0CL 9LUled1MpeYif1BQTbqaKOK7cc9r8bNN4xM1DT42MngMBsgNdsdM53Q7VDudRO0Bj2ID awxea9ElCQ/hY0KsWl9E9+WTUf+qimSErWWxQxz3fqtKpFoJA8Zn/PxDPqlX0paVymyQ 2bPvZwqKkdFKxTf+xtA6OF9D5iWjvN/7mSbq8dKDulGFiYjecxzhvsN25mVCguJgP5Ju 6Bpv3qq8bIOCJi1XK1icPlDfcaBkuByUbsreGe5JivhFT5w2WcEKdOqkeca7SYU6yQTu /JPQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1713730517; x=1714335317; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=yhEpFsgveosk8aVqC+mv6nRe6O8lSRIF73LILwNl1oE=; b=cehO+dhmRBGDCzRP6zYpPcDXIgkfgcxHMLA1nE2HYPP8S7swwpdlhAo37ZkcP8iS6O wjz43Pzfo5Ku8y1n5qX0jL52XJQmhr1VLCGJpswaMK5M8WW4qBFTy2he3N7BE+494aTY EtZuMnt1UupL5z+W8N0FFRzvzQZz42xQUxllNyxSr6MAzzrY63IRnS0Wa9jjnWkdZ22Z t9xDEg/9gNs0HAV3Q6yFTfHJ0uFJzyXBvcJaI9Mf1p1xHDFsNZj7Bl5aBrvyfMzoAAzq 6qGYxFXAELHRSP5GjXWpDtyGcVxeh96xhIZ9Eqx0C9dQjkF8mQf/m6OilYPbvbqErtor +kFw== X-Forwarded-Encrypted: i=1; AJvYcCWTW8RvXQgL77Lp7B+dkpplycE8zApADeOGjAvZS0UzFZZm+sx6u0u0z5H2LW+n1+ut0/MXzgMGzBI0hnHDuTEe3CttoUrMuooqFwT8EGFVWl4Z X-Gm-Message-State: AOJu0YziZ5qaOvXzh8GK/AQUFrFNzsZC9R6VjfKNsGLzLsVDbCGcyK2Z izIVXqphGrrkCgZv1onF6l+CwJ0YJj00kIW6CaZ8PlWHyr0WXTtS4HH0s+NZVnPx9pQcr/myQLm d86PLelKLHfVIWKZ03Q6Usv9bUUM= X-Google-Smtp-Source: AGHT+IGFCqBMQ4vNHxanvEOtZsNUqTxbaIMfQ5CWtYxILJ6yBOmgK0x2F9AQTzOgX6upl5viluUjrFBJjGQ1ZMZyGoM= X-Received: by 2002:a05:6214:4019:b0:6a0:6523:3f06 with SMTP id kd25-20020a056214401900b006a065233f06mr9365819qvb.43.1713730517326; Sun, 21 Apr 2024 13:15:17 -0700 (PDT) MIME-Version: 1.0 References: <2720974.1713710606@sss.pgh.pa.us> In-Reply-To: From: yudhi s Date: Mon, 22 Apr 2024 01:45:05 +0530 Message-ID: Subject: Re: error in trigger creation To: Ron Johnson Cc: "David G. Johnston" , Tom Lane , pgsql-general Content-Type: multipart/alternative; boundary="000000000000b9e4380616a0fa58" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --000000000000b9e4380616a0fa58 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Mon, 22 Apr, 2024, 1:34 am Ron Johnson, wrote: > On Sun, Apr 21, 2024 at 2:58=E2=80=AFPM yudhi s > wrote: > >> the partition drop from parent is taking longer as it scans all the >> partitions of the child table >> > > Does the relevant supporting index exist on the child table? > Yes all the child tables have foreign keys indexed. Again I don't want to divert the main topic(trigger creation) . I will provide the exact test case how it puts exclusive lock and runs longer as scans all child partitions (which must be using indexes though) but as the number of partitions increase the time of drop partitions increases. > --000000000000b9e4380616a0fa58 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable

On Mon, 22 Apr, 2024, 1:34 am Ron Johnson, <ronljohnsonjr@gmail.com> wrote:
<= /div>
On Su= n, Apr 21, 2024 at 2:58=E2=80=AFPM yudhi s <learnerdatabase99@g= mail.com> wrote:
the pa= rtition drop from parent is taking longer as it scans all the partitions of= the child table
=C2=A0
Does the rel= evant supporting index exist on the child table?

Yes all the c= hild tables have foreign keys indexed.

=C2=A0Again I don't want to divert the main topic(trigge= r creation) . I will provide the exact test case how it puts exclusive lock= and runs longer as scans all child partitions (which must be using indexes= though) but as the number of partitions increase the time of drop partitio= ns increases.=C2=A0
--000000000000b9e4380616a0fa58--