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 1m34ho-00070R-HZ for pgsql-hackers@arkaria.postgresql.org; Mon, 12 Jul 2021 22:47:16 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1m34hm-0001kk-IB for pgsql-hackers@arkaria.postgresql.org; Mon, 12 Jul 2021 22:47:14 +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 1m34hm-0001jo-58 for pgsql-hackers@lists.postgresql.org; Mon, 12 Jul 2021 22:47:14 +0000 Received: from mail-ed1-x52e.google.com ([2a00:1450:4864:20::52e]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1m34hi-00070x-CA for pgsql-hackers@postgresql.org; Mon, 12 Jul 2021 22:47:13 +0000 Received: by mail-ed1-x52e.google.com with SMTP id t3so30351934edc.7 for ; Mon, 12 Jul 2021 15:47:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=enterprisedb-com.20150623.gappssmtp.com; s=20150623; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=VyaNLnuuVV9qNkfM7zfIt7xixKVBGtF7DDWwpeO6w0g=; b=e5/RaJ3m5p4YT+ozkFtNVHFwBWdi+Ec0qh3BODE9pgnUzF8Fd2AKc4VWdZifEa4riU 7snkxmkqfHE92YrzsG5oYPc1Il569uLfLX2fAFlg96W1xqWj2Ym88RX1Q0wGRtztkgjy WzWNqzlk1PA5oAq8lsoznJRQgjl2HdDnPrJYRiYi4qi7KKinGnvcSyzFvEMq/1cZn2/k ecYDRq0lMwVX2Xuu81HYW411NpHY+1pDVdK6uSlN5BmZZOH7u0oyGb4XMpd1O0k39wxD aKh8T29oClL78ytspKFYcwZsG9nKLF+tDvz2futPdf4NRw1K06B6hC2mb7dqt0fQqEqe 7oSQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=VyaNLnuuVV9qNkfM7zfIt7xixKVBGtF7DDWwpeO6w0g=; b=dhH7dRgZUT9VIfXhmwMMiIQFjsAd7PdiBU1TXBb3r0553Ac7KQ7ILGx4bNmNaK7GBN ub1b50Lk1xRPOKAhkONmuk05Yu/rYqffOgOZXTtLzb+R8LukRdy3ewjLpdfTWfws4SHw sk8jXKBkvXMKCGtECH4r9j1FUTb7u3DgCQpBNfg4o+nrut+P3ThWaTp8a26Zh/n7yY/g IC5CyiJzfgHpxe/xKmnOlVmUWAH2Q/pwNoeraYtRqw40QYgYm3qjQGEogewq/119uYxu Th3T3T4fejlwCH7wHI4Y3QwJsofWIvZ02xTbFlAV5ABt5fAZdvnWboVOHuSQJfh0l5W5 +S+Q== X-Gm-Message-State: AOAM530K3zFDX7sG40gx4Hfag3beVVWxYdVYb6FOqBcJjNHRR22FbsSW xOh/drbn8UiPII1+lwS3BOeS6y0wMJ+CN8CIYJ3RW4ZLtn0JBCqwwrEzoFvYMEBDbAKZPtzGau0 nXm96GtmW7ftopmTrgCc46A7RtqqKTBaTEBKvypH4PR1GlFuV75EiBNG3oz87edVg2k5FL6l/aH Gmvu1rp3flxJStSonRQKt93A8gSDr6X6DJKfFQH6eIHxVc/mY8JsQwSVf/6xTheqLviGVMJ4Q61 jU6/fZHAbq3npZ08cCRs5u095mMqSNGvFt04w== X-Google-Smtp-Source: ABdhPJxIL2eWDx+gojuuDGe+C9dxgcnHnKzFEMKqgBaga5WJZb018FHtIuLYI7jximBz7al3ApFV7A== X-Received: by 2002:a05:6402:498:: with SMTP id k24mr1498224edv.25.1626130027783; Mon, 12 Jul 2021 15:47:07 -0700 (PDT) Received: from [10.137.0.18] (ip-86-49-254-183.net.upcbroadband.cz. [86.49.254.183]) by smtp.gmail.com with ESMTPSA id gu15sm3389078ejb.63.2021.07.12.15.47.06 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 12 Jul 2021 15:47:07 -0700 (PDT) Subject: Re: proposal: possibility to read dumped table's name from file To: Daniel Gustafsson Cc: Pavel Stehule , Justin Pryzby , Tom Lane , Dean Rasheed , Stephen Frost , Surafel Temesgen , Alvaro Herrera , vignesh C , PostgreSQL Hackers References: <20201110200904.GU16415@tamriel.snowman.net> <20201117215321.GF24784@telsasoft.com> <502641.1606334432@sss.pgh.pa.us> <20201128234945.GM24052@telsasoft.com> From: Tomas Vondra Message-ID: Date: Tue, 13 Jul 2021 00:47:05 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-CLOUD-SEC-AV-Info: enterprisedb,google_mail,monitor X-CLOUD-SEC-AV-Sent: true X-Gm-Spam: 0 X-Gm-Phishy: 0 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 7/13/21 12:08 AM, Daniel Gustafsson wrote: >> On 10 Jul 2021, at 17:47, Tomas Vondra wrote: > >> So if it was up to me, I'd go back to the original format or something close it. So something like this: >> >> [+-] OBJECT_TYPE_PATTERN OBJECT_NAME_PATTERN > > That still leaves the parsing with quoting and escaping that needs to be done > less trivial and more bespoke than what meets the eye, no? > Yes, it'd require proper escaping/quoting of the fields/identifiers etc. > As mentioned upthread, I'm still hesitant to add a file format which deosn't > have any version information of sorts for distinguishing it from when the > inevitable "now wouldn't it be nice if we could do this too" patch which we all > know will come. The amount of selectivity switches we have for pg_dump is an > indication about just how much control users like, this will no doubt be > subject to the same. > I'm not going to fight against some sort of versioning, but I think keeping the scope as narrow as possible would make it unnecessary. That is, let's stick to the original goal to allow passing filtering rules that would not fit on the command-line, and maybe let's make it a bit more flexible to support other object types etc. IMHO the filtering rules are simple enough to not really need elaborate versioning, and if a more advanced rule is proposed in the future it can be supported in the existing format (extra field, ...). Of course, maybe my imagination is not wild enough. regards -- Tomas Vondra EnterpriseDB: http://www.enterprisedb.com The Enterprise PostgreSQL Company