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 1u8sj5-00D3dB-En for pgsql-general@arkaria.postgresql.org; Sun, 27 Apr 2025 03:30:43 +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 1u8sj3-008Z3s-As for pgsql-general@arkaria.postgresql.org; Sun, 27 Apr 2025 03:30:42 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1u8sj2-008Z3k-U6 for pgsql-general@lists.postgresql.org; Sun, 27 Apr 2025 03:30:41 +0000 Received: from mail-lj1-x233.google.com ([2a00:1450:4864:20::233]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.96) (envelope-from ) id 1u8sj0-002GkM-0C for pgsql-general@lists.postgresql.org; Sun, 27 Apr 2025 03:30:41 +0000 Received: by mail-lj1-x233.google.com with SMTP id 38308e7fff4ca-30bf5d7d107so29563521fa.2 for ; Sat, 26 Apr 2025 20:30:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1745724637; x=1746329437; 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=mph0EV7XiYGFGEiydSqE6IDIZ6TiuUcfXtzNzmjfzdU=; b=MBO/nUfiVeg59PQEJVD+LChxxfHmzyR5dLPA0o1rbRVkgav/4ADu62/4a/r9TukyWk 3a7KWI28imNsI47XsortneFvGO4+qBUbERO9WqndCYq7sy/mbZxJXyMJ0qa8oxgvF/Wu XR2i4YFyWRYrS8YeK2ftYIa8GycnunKNlVjNp1Cbm6BK1IuGrUKhWHl1W7DWa7sH5fcZ qFDwxMQShXRDgR8wl5wvQLBZMv7R5WyfnrEhxcXa/+Xj7P2VHbuafV7EyIs2GrPip1vl JPUyCRqyrwos/4FLVYogp8v+VuQl6V1Ni6ihjVshFW3SLCnLVU3YB7dVcnBAO/whHZLW /b5w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1745724637; x=1746329437; 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=mph0EV7XiYGFGEiydSqE6IDIZ6TiuUcfXtzNzmjfzdU=; b=sKWlXgJTBDYKiDil8fwU/ApYHjay3KhnEqUXjhl55gsb+095Kc5KRhfJTds6iBUMVO ZcmoYYiZAZlQLPd9j92a+KEicuE6NVO44gg7ZFnSohRbnmmmiebqfOoo9TpEp0J6WZJX Uy43CWX0a4WKDEvCZrj1fHPnIstTrOFPl9AUAbApPCqaxbezrx+IIHHsxd3RxgJyVjpv 58Pf3rxa3JTggYgO6RRI/pJ2nwIu5EaO2r9HkQ8c73hFlFrNPi3Eq933uB/wxOsCcYqK mhXaXBw+/slW7n76BtC9+aYN0yhvmFzat4j/3PPZj9nI4QW3WVNljQmms+CvIOrggexw +8dg== X-Gm-Message-State: AOJu0Yz9gNRkIEwoxmC4uyWsEswaWqp0Hl8Wir63/OTWsBXtdPVMv4Xz ATFs6hT0ayNTH6KO/oEobmJZQBa6wDH5w3k0Ftpb79w8vLjbt54tQAeM5933iWmgRGcOMCE5CxQ 9T9IXTmWnx/ddqpBaQ3pbnGgtAFY= X-Gm-Gg: ASbGncudKv3cCYV0wzszACwws7Y8bI3TMzStFg4nOMAdi4aFDQ7kc4wMv817IN+oTYk UJxQohQeyMd6syXtr1/Enw+vAqD6L7ZZY57pQLRJd6Y4NFvigtI8bwAf+J9jNKX5wwlrYO7Uk5j 2lgKezvwQXXSxNgGBNQ03qQMrthDYP3OqeN8ph8uibmzIl88ncl+6Dyi9t X-Google-Smtp-Source: AGHT+IGd1qMmsVuu8C9xUS/csmD40b+kKRH4WYKxWNVQIzzal0uIOCJmyG6wgOW+kWTXDXyfBdjWUK6MGAQGkVFOJ1o= X-Received: by 2002:a2e:bcc3:0:b0:30c:7a7:e841 with SMTP id 38308e7fff4ca-319080e2700mr26691351fa.34.1745724636359; Sat, 26 Apr 2025 20:30:36 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: David Rowley Date: Sun, 27 Apr 2025 15:30:24 +1200 X-Gm-Features: ATxdqUESi9yhejmzbYaGmSr7yNv1r52ItKI72qGdUsTo8qXnxt3fmPsHYK34P2M Message-ID: Subject: Re: Changing default fillfactor for the whole database To: Marcelo Fernandes Cc: pgsql-general@lists.postgresql.org Content-Type: text/plain; charset="UTF-8" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Sun, 27 Apr 2025 at 14:31, Marcelo Fernandes wrote: > I have a scenario where virtually all user tables in the database will need to > have a lower fill factor. > Does this make sense? Have I missed something about being able to change this > on a database level? I suspect that it's possible that you can use an event trigger [1] that triggers on CREATE TABLE to get what you want here. If the docs don't give you enough information, then maybe [2] will have something you can work with. I've not used them much, so I don't have any recipes for you. David [1] https://www.postgresql.org/docs/current/sql-createeventtrigger.html [2] https://github.com/postgres/postgres/blob/master/src/test/regress/sql/event_trigger.sql