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 1mSfpa-0003sC-JN for pgsql-hackers@arkaria.postgresql.org; Tue, 21 Sep 2021 13:29:06 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1mSfpY-0002Uq-N6 for pgsql-hackers@arkaria.postgresql.org; Tue, 21 Sep 2021 13:29:04 +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 1mSfpX-0002Ti-RI for pgsql-hackers@lists.postgresql.org; Tue, 21 Sep 2021 13:29:04 +0000 Received: from mail-qv1-xf30.google.com ([2607:f8b0:4864:20::f30]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1mSfpQ-0005F0-HG for pgsql-hackers@postgresql.org; Tue, 21 Sep 2021 13:29:03 +0000 Received: by mail-qv1-xf30.google.com with SMTP id cf2so13452164qvb.10 for ; Tue, 21 Sep 2021 06:28:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=2ndquadrant-com.20210112.gappssmtp.com; s=20210112; h=date:from:to:cc:subject:message-id:mime-version:content-disposition :content-transfer-encoding:in-reply-to; bh=CvFwnFLXqX9d2DOt1AcIT/pi4ayw0IcEMcexBsZcc8U=; b=3+scgkdXTFIs4oA81jtRB7fvSUsZiD6jurKiV2BkxHSwGYXC/vh4eTRt1yzmHxIyGy +3FTuOhsEaxRHkbII4U9JDh5AlSwrit/c/CgAKk2WyIGyKun6ajHK1eqDK5RWEhXBIGf kD3rM0zYrBaJjZtib1oXirwW+C4sixn7CzaDcAA0gvD7WDPJBPB3T0IQOHS1MMvtKyUp nf3BliNz2oiWAuOAnW/EZgMsuGd87THlshA27ufX30FJBsSQiJN2KrW+WfLjjfLz1Ofx Zxr89v/t9r5Czd1H3n8Zq24hqJ0x3OAS6zlBBL+MDWY1BpjdOoRbnA2KGJq3BgC9fwsC SiGg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:mime-version :content-disposition:content-transfer-encoding:in-reply-to; bh=CvFwnFLXqX9d2DOt1AcIT/pi4ayw0IcEMcexBsZcc8U=; b=Z4CjKhKkvAsuBIDguUkU1MiACOK9SnANoIs1abGRq23Dv9/3zzYTqmPNB8UFUreDZf fmab2WhtsK3jjidtH33Ro4o8pOJCxhsfjdTkZ3yCXgpWYsD4ixAPgnGKbg+h6rD9QNwe DuKXHm+P3ko3iJRf0ug9iQQX78Ge6t4QAUxID9yMQuAP+mQqbOpjPa4aVUu8Ma64NEcy 7WElMF5puOfa1Z5ea19NX3CMBJGShP5y0CXcozzBM2p31rePv34Vn7/rVAl6VpKlUjYg MOx8O188H5z9jlE4QWSTKf18wEFSdKW4P1MPLuQNU4I3ZASYmMEvegI3tfuOBYTxzQDb HtaA== X-Gm-Message-State: AOAM532OtcJxPIaHRDDDjFLOCZUwlGcdIHe5uv2nLh70s0T68lnFcGjR ap+Vf09HmDJm13TnLFfGoSisZQ== X-Google-Smtp-Source: ABdhPJyatdveTfZ3O74TO+DEwGpB4inzeX60jl7oaLhIySr23ndnuN9sdyGXufomeYcPE8EHiUkKSg== X-Received: by 2002:ad4:560b:: with SMTP id ca11mr31000314qvb.10.1632230934801; Tue, 21 Sep 2021 06:28:54 -0700 (PDT) Received: from perhan.alvh.no-ip.org ([201.186.208.208]) by smtp.gmail.com with ESMTPSA id q184sm14122561qkd.35.2021.09.21.06.28.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 21 Sep 2021 06:28:53 -0700 (PDT) Received: by perhan.alvh.no-ip.org (Postfix, from userid 1000) id F34432A07D0; Tue, 21 Sep 2021 10:28:51 -0300 (-03) Date: Tue, 21 Sep 2021 10:28:51 -0300 From: Alvaro Herrera To: Daniel Gustafsson Cc: Pavel Stehule , Tom Lane , Tomas Vondra , Justin Pryzby , Dean Rasheed , Stephen Frost , Surafel Temesgen , vignesh C , PostgreSQL Hackers Subject: Re: proposal: possibility to read dumped table's name from file Message-ID: <202109211328.ywlhshay242s@alvherre.pgsql> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <60D482DD-2F63-4627-B154-D6C46A7DAEBE@yesql.se> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk I definitely agree that we should have two files, one for config and another one for filter, since their purposes are orthogonal and their formats are likely different; trying to cram the filter specification in the config file seems unfriendly because it'd force users to write the filter in whatever alien grammar used for the config file. Also, this would make it easier to use a single config file with a bunch of different filter files. On 2021-Sep-21, Daniel Gustafsson wrote: > I'm not convinced that we can/should change or remove a commandline parameter > in a coming version when there might be scripts expecting it to work in a > specific way. Having a --filter as well as a --config where the configfile can > refer to the filterfile also passed via --filter sounds like problem waiting to > happen, so I think we need to settle how we want to interact with this file > before anything goes in. I think both the filter and the hypothetical config file are going to interact (be redundant) with almost all already existing switches, and there's no need to talk about removing anything (e.g., nobody would argue for the removal of "-t" even though that's redundant with the filter file). I see no problem with the config file specifying a filter file. AFAICS if the config file specifies a filter and the user also specifies a filter in the command line, we have two easy options: raise an error about the redundant option, or have the command line option supersede the one in the config file. The latter strikes me as the more useful behavior, and it's in line with what other tools do in similar cases, so that's what I propose doing. (There might be less easy options too, such as somehow combining the two filters, but offhand I don't see any reason why this is real-world useful, so I don't propose doing that.) -- Álvaro Herrera Valdivia, Chile — https://www.EnterpriseDB.com/ "How amazing is that? I call it a night and come back to find that a bug has been identified and patched while I sleep." (Robert Davidson) http://archives.postgresql.org/pgsql-sql/2006-03/msg00378.php