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.96) (envelope-from ) id 1vNWSi-005JTZ-1Q for pgsql-general@arkaria.postgresql.org; Mon, 24 Nov 2025 13:18:36 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1vNWSg-000yiH-2P for pgsql-general@arkaria.postgresql.org; Mon, 24 Nov 2025 13:18:35 +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.96) (envelope-from ) id 1vNWSg-000yi9-18 for pgsql-general@lists.postgresql.org; Mon, 24 Nov 2025 13:18:34 +0000 Received: from mail-yw1-x112c.google.com ([2607:f8b0:4864:20::112c]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.96) (envelope-from ) id 1vNWSe-001EaU-18 for pgsql-general@lists.postgresql.org; Mon, 24 Nov 2025 13:18:34 +0000 Received: by mail-yw1-x112c.google.com with SMTP id 00721157ae682-789524e6719so54943837b3.1 for ; Mon, 24 Nov 2025 05:18:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1763990310; x=1764595110; darn=lists.postgresql.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=1KwkoQHZmhcg1hm1m4cJVUGyzN5A0NDNlqJE0RaZ2cA=; b=Jn8MUYECECu5fc5L+jApgQ8ZQFaQHY8gW+R+And9uUiF1OKRngjEOhdfBPlofPskpw DX6gyWSH1BYvdP7jDsxDD2eX6exkZExgOwG8pFDFAhhx5ImxAOKZD6ldfD72cfimUe0A 3tqB0nK6e4E17LvHjKtYDISxfS7hVURtzA9kvLx8/6YZS8FYOOq6J+ss30+vAu2yphfA BNTcJ9HsEs6SmmgmDtqq828iTJjxl2pMahExTQWICzt8dsZaTXUrEy/vLfVHTIVvdUu3 HUUddvHWHXi8OTR2qjl+XNk/R56AzsfkbWNQJHzvtegNyaEQYKoTj5ndQz697x+nswnY 8OPA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763990310; x=1764595110; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=1KwkoQHZmhcg1hm1m4cJVUGyzN5A0NDNlqJE0RaZ2cA=; b=BdY3bV00qFOTehCYNl2teo8690hZRRq+XxCt4vDf6Il07jtu/fKzwWIs4aGhmXU7fo uqlLKjDySCmIUtRns+9lHoKQb37hv4c+mgYLt65zdgCLFXqHoCPat7ofuhcwum8GIwGt JwYbBQ9NTxkikRC2PpnX/Mk+jMMuoMTnbEl9ryeQV99wTZuZsy1KnpUz9Ntw6RrrylUz 4DBVO+Z83Myj2c4kPABb+sQLC3riHZX2nR4qKNW7t38EowfXOUYbaEYznOOOaIAiY+jx HgLz4SxJ4eN7EM+RtguK+AuUR+uaCa1JNd4it/cw+1K2UzBiS/g5kCCniy+26UoZQzRN fhaA== X-Gm-Message-State: AOJu0YyH2e/kEs3OZyhZnMFFS27mTBJf42CBtnLv1M5kFzMrZpZqAiM7 gWOHRkAt0Lql7+sxKF2YTmbvtZOU7w1r/6G5wuIvN7LNdQR7Q58U5UmTJDoAn0Wxbuhsan4yqrN TZZgncM/MKf19KGlkCAlzef2WenaDp++CzQ== X-Gm-Gg: ASbGnctwq3gLmG7ay8BJRpdZuy3KIQzI17sosJtcpVZyj3ltf5h2ndiXdozFjSjLoPq iYb5/kPMa/wi5w8WGlDpM/tXRV3bmJIkQYNAMuFjh/Tc6yfHDFhM4PhWwhcRq+GlpjZJgv+QNZ8 5K++94v2zYBD9br+yDN2ecQRK5zbgPPy70ReEPJTCB/tUSDFn11p48B9JjOxHivKSXmd/iP1V1R tJ7jlXHgJSB0THAP8eHCgdc7A+W1K5bwqPfQFM7Qjztk5DIf+ZkzWz0PDRXkfSUdswD/3DsRu8M Jcz9/zUeOEUtLQBTzzTOkmgDOPhMORU= X-Google-Smtp-Source: AGHT+IGHdSwQPukdCYntWxDXmu7hZaBdvDhbb6v1QDrusiUcAprap8N8rJxVLVRY9G7douBIZ4oSgo3wVKYOJ4LcVvg= X-Received: by 2002:a05:690c:6e03:b0:786:4949:b18d with SMTP id 00721157ae682-78a7b9ba83cmr124581857b3.4.1763990309911; Mon, 24 Nov 2025 05:18:29 -0800 (PST) MIME-Version: 1.0 References: In-Reply-To: From: Bernice Southey Date: Mon, 24 Nov 2025 13:17:53 +0000 X-Gm-Features: AWmQ_bluj1foP3Jub6dwa8dQj2oTTHTcOOxbwkEHSn3IYN4FY4JM3PAuLuez7YA Message-ID: Subject: Re: Schema design: user account deletion vs. keeping family tree data To: Christoph Pieper Cc: pgsql-general@lists.postgresql.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Christoph Pieper wrote: > Question: > From a PostgreSQL point of view (database best practices, data integrity,= performance and long=E2=80=91term maintainability at millions of rows), wh= ich approach would you prefer, or is there a better pattern for this kind o= f =E2=80=9Caccount can be deleted, but genealogy should remain=E2=80=9D use= case? I can tell you what I'm doing. It solved many design problems, but I don't claim it's "best practice". I split my table in two. 1 - columns that I can keep indefinitely 2 - personal data That way I just delete the personal data row when I want to remove it. Thanks, Bernice