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 1pGSjh-0004L1-UQ for pgsql-general@arkaria.postgresql.org; Fri, 13 Jan 2023 22:41:22 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1pGSjg-0004E0-Qr for pgsql-general@arkaria.postgresql.org; Fri, 13 Jan 2023 22:41:20 +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 1pGSjf-0004Dr-OT for pgsql-general@lists.postgresql.org; Fri, 13 Jan 2023 22:41:20 +0000 Received: from wout3-smtp.messagingengine.com ([64.147.123.19]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pGSja-0006HX-4q for pgsql-general@lists.postgresql.org; Fri, 13 Jan 2023 22:41:17 +0000 Received: from compute6.internal (compute6.nyi.internal [10.202.2.47]) by mailout.west.internal (Postfix) with ESMTP id 1B90E32005BC; Fri, 13 Jan 2023 17:41:10 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute6.internal (MEProxy); Fri, 13 Jan 2023 17:41:10 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aklaver.com; h= cc:cc:content-transfer-encoding:content-type:date:date:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:sender:subject:subject:to:to; s=fm2; t=1673649669; x= 1673736069; bh=NmE1bW5kZu5Kf2W2rSMVhr4VaAVAYlUN95xB2NfbVV4=; b=d bF3fnbmy9S7jLkcZMd3Hao1e080DqlvSyDXptJ8dGhUtzncXExPgZXYDOCrHUZcd dRrX25yLuw+f3rjNfjgqcXQzqVhmqtmJAJsSFSobikN3pf+gCfD81qPP5kN76B/X YFCr0HCgunHrJPxB2acTQTbzhN1e1qACN0+PPcu3CANQ5HoldlxuR6JLuZN3LZUW FS1oy3FAftnjoQqwpcq9gL4IuKgYUodQE5JrTAmt1Ov+u6quhtUqH0EvXuvPDCj8 cZ+PBFqdC+sBvQyN4r1wLjMWSuDtdlKM+qeDiceAUmLimXa1fmvQmexySADqtJnQ xHvAV1pn2TT0B6i1PnnXg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:date:date:feedback-id:feedback-id:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:sender:subject:subject:to:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm3; t=1673649669; x= 1673736069; bh=NmE1bW5kZu5Kf2W2rSMVhr4VaAVAYlUN95xB2NfbVV4=; b=H bs/PT0RwiQtbzHxqJjj8NLOsF+MKYJVa6Llcy75BYsrQlEevXhanwg2Jw9A9OS5S TTfn5YAybHUW43R07D+bo+QK0jfoFtoMkny70guMKoG4BGVnsPNFQ8CULZmTOoj8 b/DZeHZXiwcDqxIw+1inCzBU7lQdDqUxjrg5dKz+w8N0SyQVbBogHjtcfMshCFHj jWxKmNEqgQEgnLz57ivsRRNFSoOtSCXLpTEMwCcSuiLd1Ti5WPZo/hlFYCcfzxkO X29uej5EiWsfHF85FL9MSRceF8SyYtrP2p6QJ4ouZMLtWRtOHkrUDVNPmAWwmMdr Ukp5mmu/3fL+t7CeCSC7w== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvhedrleelgddtudcutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpefkffggfgfuvfevfhfhjggtgfesthejredttdefjeenucfhrhhomheptegurhhi rghnucfmlhgrvhgvrhcuoegrughrihgrnhdrkhhlrghvvghrsegrkhhlrghvvghrrdgtoh hmqeenucggtffrrghtthgvrhhnpeejgedthfeuhfetgfffvdehudelteegjeduveffkeet geejieehueduleelgfffffenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmh grihhlfhhrohhmpegrughrihgrnhdrkhhlrghvvghrsegrkhhlrghvvghrrdgtohhm X-ME-Proxy: Feedback-ID: i76984098:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Fri, 13 Jan 2023 17:41:08 -0500 (EST) Message-ID: <53c0b4d4-b80a-a35b-ce18-61058794c9bb@aklaver.com> Date: Fri, 13 Jan 2023 14:41:08 -0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.6.1 Subject: Re: Intervals and ISO 8601 duration To: Ken Tanzer , Tom Lane Cc: Sebastien Flaesch , pgsql-general References: <953416.1673536094@sss.pgh.pa.us> Content-Language: en-US From: Adrian Klaver In-Reply-To: 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 1/13/23 14:17, Ken Tanzer wrote: > On Thu, Jan 12, 2023 at 7:08 AM Tom Lane > wrote: > > What Postgres actually stores for an interval is three fields: > months, days, and microseconds. > > > Is there a way to view/extract this raw data for any given interval? > > (I'm asking because of an issue that came up about intervals that were > "equal but not identical.") 1) Can you provide an example? 2) I don't know how to reverse an output interval to it's input value. > > Cheers, > Ken > > -- Adrian Klaver adrian.klaver@aklaver.com