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 1kCmj7-0004Xz-Px for pgsql-hackers@arkaria.postgresql.org; Mon, 31 Aug 2020 16:32:13 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1kCmj6-0005vp-FP for pgsql-hackers@arkaria.postgresql.org; Mon, 31 Aug 2020 16:32:12 +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 1kCmj6-0005vi-2v for pgsql-hackers@lists.postgresql.org; Mon, 31 Aug 2020 16:32:12 +0000 Received: from mail-wr1-x441.google.com ([2a00:1450:4864:20::441]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1kCmiy-0002fb-LN for pgsql-hackers@lists.postgresql.org; Mon, 31 Aug 2020 16:32:11 +0000 Received: by mail-wr1-x441.google.com with SMTP id o5so2684055wrn.13 for ; Mon, 31 Aug 2020 09:32:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=2ndquadrant-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=3AQivuX9Lep1Lh/qDw28+cOf5fGQOS4uPJDUHZiiOh8=; b=mhHL6amFQ3GuncAoRXeOv7N/+MoYTSyVLv88i1YaCHEtFDMgVijjIIDlyXysFnJblQ OpMGYdolYUwqjYnwG9B7HqKPyrdoiClTqUg7VA8RLKPxv0hOwNowvHw99gLk2k4DG6/L wnV1TWq9Ymm32belf3flvh2PXzvztnsA8+7bP+gfRFCzwn+p4C1P71BM3v25jn7xdV98 kOvWfn+eMep/69wHExtNN+1uIPin5yIZNCnvVrDrzjTYzPPmdHHTQC4hrgKon1TJnM2H BwYQFyKjbFgGThtdLDa3apMZPu76NUrfJvsUwB7OMu7MRhNIkrSgo96CjywOQahQDcav qfuw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=3AQivuX9Lep1Lh/qDw28+cOf5fGQOS4uPJDUHZiiOh8=; b=H9lojL2AI5ayvsieZpr3ArEciYGw70/pX8XoT+XLLy0+a66ct3Htv94mIqxtuMftMX E6OMJW3bP4wS2mu4Bs3PcD5NKFJtCrzEoScaR50oSnUWwf/qxU6BpO2kFH3FlzJI1cGE 6mqDepwq3ZscyzlCLj/o41AzWtUFiSQhX+t3Xp3U4RqfAbLDk7vODB054j6otZjzCht0 cR9keew6bPFqDiPMRMAfleqEsNK3tNA117lOr6crMKhIwGF0uo5oA3nqn3jpxJ7BbZan Z6kYZF0Nou3C5DYW7JJ5BZZkNezAvXxmWk8pJJmWRmKu11scRq2HsyhnilLykDX+Jg3/ 3IbQ== X-Gm-Message-State: AOAM5334XDA/bVqcT8ItIryfgjWj8pmD0KL34C09GNlUV5+Hfl3CE2td xCmVLWkRPsZOOPsMp9nrn1aeow== X-Google-Smtp-Source: ABdhPJwL5aGA5K+xkfrxwf9KbGOZPfUUQlVnCPQGPKv5hydsqrpa3Np1oJ+UkSDS60XAJd6nXVgjNA== X-Received: by 2002:a5d:56c7:: with SMTP id m7mr2353323wrw.322.1598891523507; Mon, 31 Aug 2020 09:32:03 -0700 (PDT) Received: from localhost (ip-86-49-253-216.net.upcbroadband.cz. [86.49.253.216]) by smtp.gmail.com with ESMTPSA id z8sm153996wmf.10.2020.08.31.09.32.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 31 Aug 2020 09:32:02 -0700 (PDT) Date: Mon, 31 Aug 2020 18:32:00 +0200 From: Tomas Vondra To: Alvaro Herrera Cc: Tatsuro Yamada , Julien Rouhaud , Pavel Stehule , PostgreSQL Hackers Subject: Re: list of extended statistics on psql Message-ID: <20200831163200.jp6eqbaaupb6hxac@development> References: <20200831153053.a343pjgumahiejhw@development> <20200831161809.GA31337@alvherre.pgsql> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline In-Reply-To: <20200831161809.GA31337@alvherre.pgsql> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On Mon, Aug 31, 2020 at 12:18:09PM -0400, Alvaro Herrera wrote: >On 2020-Aug-31, Tomas Vondra wrote: > >> I wonder if trying to list info about all stats from the statistics >> object in a single line is necessary. Maybe we should split the info >> into one line per statistics, so for example >> >> CREATE STATISTICS s (mcv, ndistinct, dependencies) ON ... >> >> would result in three lines in the \dX output. The statistics name would >> identify which lines belong together, but other than that the pieces are >> mostly independent. > >Yeah, that's what I'm suggesting. I don't think we need to repeat the >name/definition for each line though. > >It might be useful to know how does pspg show a single entry that's >split in three lines, though. > Ah, I didn't realize you're proposing that - I assumed it's broken simply to make it readable, or something like that. I think the lines are mostly independent, so I'd suggest to include the name of the object on each line. The question is whether this independence will remain true in the future - for example histograms would be built only on data not represented by the MCV list, so there's a close dependency there. Not sure about pspg, and I'm not sure it matters too much. regards -- Tomas Vondra http://www.2ndQuadrant.com PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services