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 1mk7T0-0003XH-00 for pgsql-general@arkaria.postgresql.org; Mon, 08 Nov 2021 16:25:54 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1mk7Sy-0008OK-VN for pgsql-general@arkaria.postgresql.org; Mon, 08 Nov 2021 16:25:52 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mk7Sx-0008O9-SW for pgsql-general@lists.postgresql.org; Mon, 08 Nov 2021 16:25:52 +0000 Received: from wout5-smtp.messagingengine.com ([64.147.123.21]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mk7Su-00032f-4U for pgsql-general@lists.postgresql.org; Mon, 08 Nov 2021 16:25:51 +0000 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.west.internal (Postfix) with ESMTP id 5F2333201E6D; Mon, 8 Nov 2021 11:25:44 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute4.internal (MEProxy); Mon, 08 Nov 2021 11:25:44 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aklaver.com; h= message-id:date:mime-version:subject:to:references:from :in-reply-to:content-type:content-transfer-encoding; s=fm1; bh=1 vcWOQrLCIMVMgnZfJH++OqtWRnk+S9gQEOQK84H0xk=; b=Zb3UkEvshhXLFy4iD 1tR0pBWrVaSHqZjRaT2sFTNlfaFgcsHto1Dq0lVXsybVSxCpS3AlRmhVMy9ilNt4 xLFmetY9XfZk5uksaiMBt2YEyUFlmRndn7/Q7Sz0gbTp5a9+lCHSTTsq0IFNbtCg mH8efyF3QUEpeJZwdQ2JjiXPO5GAvjUDqyWEsnmlyAOjxpkkUdmES+8CRp9Txdun tgcXT1LlddeXeLLJ1UXGdFVbP54w1YBMQs3Bhg32va/niXvtvujhMfOf2BkT+VN3 tV7E/amFNgVc+wvfmxQGuta0mDXfiIn+ny/OerL8uHVsaMUCeJVEPAaeAaXD9oBD Nkgxw== 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=fm1; bh=1vcWOQrLCIMVMgnZfJH++OqtWRnk+S9gQEOQK84H0 xk=; b=cTUi0uqviy2J+JusGQ08jLByosyTZ0siJy+kfhqFJzTx1OaWVYYpGA/0C 5eHE0yg2Y14snC0cabDpaWUp5qbGcNpliDA8B4FBIpvDkWHhpBxPrs2cvgrS0cWe cNXJoiuhV0ss17aPtyx66bAFzyzSiTQtS1M0Dx9XO/zzzYqkTJ6DxEc4YMefRtpo Hk+hxgz9XTmMmLQlnlYi2cqBtgo1U7bmaNRw+ieAt756LEDdO+19Kk0jRz5F56dH ycBIfOqfk59Eh/IDzrm/ivXg02TF6T8PfyWAIKj71NlFdyuiqq09PscahbV3ts4/ wnGinLTKLdU4Dvi5TEV5WkTqFKSPw== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvuddruddvgdekjecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenog fuuhhsphgvtghtffhomhgrihhnucdlgeelmdenucfjughrpefkffggfgfuvfhfhfgjtgfg sehtjeertddtfeejnecuhfhrohhmpeetughrihgrnhcumfhlrghvvghruceorggurhhirg hnrdhklhgrvhgvrhesrghklhgrvhgvrhdrtghomheqnecuggftrfgrthhtvghrnhepleej udeludejteehhfehudevheeiieevueffffefhfekvddvheejiedvtedugfegnecuffhomh grihhnpehsqhhithgthhdrohhrghdpghhoohhglhgvrdgtohhmnecuvehluhhsthgvrhfu ihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomheprggurhhirghnrdhklhgrvhgvrh esrghklhgrvhgvrhdrtghomh X-ME-Proxy: Received: by mail.messagingengine.com (Postfix) with ESMTPA; Mon, 8 Nov 2021 11:25:43 -0500 (EST) Message-ID: <2f5d8e00-666f-62d1-8108-a0fcd02a8fa8@aklaver.com> Date: Mon, 8 Nov 2021 08:25:42 -0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.3.0 Subject: Re: Design database schemas around a common subset of objects Content-Language: en-US To: Erik Wienhold , "pgsql-general@lists.postgresql.org" References: <766855348.80521.1636243329249@office.mailbox.org> <8555f244-6bc0-51b0-9143-8caeaed150a7@aklaver.com> <1116172276.274316.1636330474638@office.mailbox.org> From: Adrian Klaver In-Reply-To: <1116172276.274316.1636330474638@office.mailbox.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 11/7/21 16:14, Erik Wienhold wrote: > Hi Adrian, > >> On 07/11/2021 18:38 Adrian Klaver wrote: >> >> My questions for this are: > I'm thinking about something like merges in Git. Database schemas for > project-a and project-b are like separate repositories and changes in core > are merged as necessary. This along with project-specific changes ("o" in > the diagram below) should result in a sequence of migrations applied to the > respective databases. > > project-a oo--o--ooo-o---o--oo----> > ___/ _/ _________/ > / / / > core o--oo-o---o-o--o--> > \ \__ \ > \ \ \ > project-b o--ooo--o-o-o--ooo-----> > > These merges (always from core to the projects) form a directed acyclic > graph from which the migration sequence can be generated using a topological > ordering. > >> 4) Are you using or have you looked at Sqitch(https://sqitch.org/)? > > Already looking into it after stumbling across it during research on the > mailing lists ;) I think of Sqitch as version control(of database) inside the version control(VCS e.g. Git). Pretty sure it will cover your use case. Since you mentioned mailing list I will point you at the Sqitch one (https://groups.google.com/g/sqitch-users). > > Erik > -- Adrian Klaver adrian.klaver@aklaver.com