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 1rAv0x-008jMQ-8E for pgsql-hackers@arkaria.postgresql.org; Wed, 06 Dec 2023 16:44:47 +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 1rAv0v-00BTGF-RK for pgsql-hackers@arkaria.postgresql.org; Wed, 06 Dec 2023 16:44:45 +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 1rAv0v-00BTG7-HN for pgsql-hackers@lists.postgresql.org; Wed, 06 Dec 2023 16:44:45 +0000 Received: from mail-il1-x12a.google.com ([2607:f8b0:4864:20::12a]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1rAv0s-0096oM-TY for pgsql-hackers@postgresql.org; Wed, 06 Dec 2023 16:44:44 +0000 Received: by mail-il1-x12a.google.com with SMTP id e9e14a558f8ab-35d6c5f9579so11633785ab.0 for ; Wed, 06 Dec 2023 08:44:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1701881082; x=1702485882; darn=postgresql.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=bstAdU5KPo0uAkaqpAsMd6RHRHTzT17c3yLh6XdVMcA=; b=W3fMOtqbMofRMlrMqYLQFtHAvvJBrextK8Kw3xu95eQcyx1/JFi6vTYnnxf1dTp3Ob CZfCWiAs34kW6j5XaniGHSXpAzfx4cslCe3Zvc0ADRsWqOsPEdwZHqTHPXHqgKIIfDyI G/+ddtcJu1CxEq3tb0sPypyurEXdyA1RMFuj+LXCCI2pE99OxHDfoFgCWrXbxr6bD5vI IptFUk5eQO2EEjplL/BP60O8GJDMnTC5P/ciacOyfW8MxxyRpnZL84nKAgxSujjta+ah xEE6fPs5tiDF2L8Fmgz8/Li1CJyQXLl1iThiz8cZwACXKZrdyTL4r43tNu0pTMJtzh1q +gGg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1701881082; x=1702485882; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=bstAdU5KPo0uAkaqpAsMd6RHRHTzT17c3yLh6XdVMcA=; b=FqIIq8Lk8YsdWsT78mtnfMyFgoc01okdM+ecEUC3I95hkymidvdBc0up0acaeCqDsC oYIU1ugUZqj3+BZFH9IYaqOlMNniXmj/URklRLb+emK1idTxATn/96ZdwB/WOjqJC0Ko Ipg2epDJ6Kp3MB5mw4HcSF2z8N4jDoNWw69DCq1HN9Md9thxKzaj0es57wIHoKWZUP50 qXwTBjNh9J1zyyqv7wgmNIvZ8Iq83HHDIti5joSS0aPhUZCCD3EDLT4BcA5LasmWbL0U TFJJHC3bfgyshsaL3YSTOPucoUMaC3aQQ7/4kPb3PQMuMd34cZZJi9yvYIfymASUXoi1 kCMQ== X-Gm-Message-State: AOJu0YyNzh6asuJcIPkzdhfnQaEsQ/3uO1EA6GxMSHvf1nqLXLDAQlup ZxHK5qek5ae2jqIRcp3nGG6+PH3o4iY= X-Google-Smtp-Source: AGHT+IGIaHvQwKXPC7FMGHYGmNjKNbKshVy1HMN0x2Lu5m7oqbRoF0dNGl0NVbiwUBh+JLQ8jPEOFA== X-Received: by 2002:a92:da8a:0:b0:35d:59a2:6909 with SMTP id u10-20020a92da8a000000b0035d59a26909mr1428865iln.54.1701881081901; Wed, 06 Dec 2023 08:44:41 -0800 (PST) Received: from nathanxps13 (162-195-168-172.lightspeed.stlsmo.sbcglobal.net. [162.195.168.172]) by smtp.gmail.com with ESMTPSA id h8-20020a056638062800b00468e80fa254sm35799jar.148.2023.12.06.08.44.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 06 Dec 2023 08:44:41 -0800 (PST) Date: Wed, 6 Dec 2023 10:44:39 -0600 From: Nathan Bossart To: Tom Lane Cc: Andrew Dunstan , Joe Conway , Davin Shearer , PostgreSQL-development Subject: Re: Emitting JSON to file using COPY TO Message-ID: <20231206164439.GC2873889@nathanxps13> References: <926ff917-8371-40ec-b5e6-ab7b0e09bdc5@joeconway.com> <315b81d4-4b67-7828-0355-3808cd14acd1@dunslane.net> <7a60faf6-e7f1-419d-aee6-10a78ea2fe81@joeconway.com> <2e7ff718-895d-83fc-46f7-be25e23b23b4@dunslane.net> <1104915.1701877459@sss.pgh.pa.us> <19a5f9d8-bd1f-9!e51-0f5b-510c1189a8a7@dunslane.net> <1110690.1701880139@sss.pgh.pa.us> <20231206163349.GA2873889@nathanxps13> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20231206163349.GA2873889@nathanxps13> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Wed, Dec 06, 2023 at 10:33:49AM -0600, Nathan Bossart wrote: > (format csv) > Time: 12295.480 ms (00:12.295) > Time: 12311.059 ms (00:12.311) > Time: 12305.469 ms (00:12.305) > > (format json) > Time: 24568.621 ms (00:24.569) > Time: 23756.234 ms (00:23.756) > Time: 24265.730 ms (00:24.266) I should also note that the json output is 85% larger than the csv output. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com