Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hWkMZ-0006y5-EL for pgsql-general@arkaria.postgresql.org; Fri, 31 May 2019 16:26:39 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1hWkMY-0000el-8S for pgsql-general@arkaria.postgresql.org; Fri, 31 May 2019 16:26:38 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hWkMX-0000cd-Ui for pgsql-general@lists.postgresql.org; Fri, 31 May 2019 16:26:37 +0000 Received: from mail-ot1-x32c.google.com ([2607:f8b0:4864:20::32c]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hWkMV-0001wG-Tk for pgsql-general@lists.postgresql.org; Fri, 31 May 2019 16:26:37 +0000 Received: by mail-ot1-x32c.google.com with SMTP id i8so9730205oth.10 for ; Fri, 31 May 2019 09:26:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:references:from:message-id:date:user-agent:mime-version :in-reply-to:content-transfer-encoding:content-language; bh=5bc4aQZV9+RC9cNFh5PGe4YpDiNQfISK0JHpOJkMnXk=; b=IOf3XJrwlVozgPaA1FNWv76PeBpWlUp2hq98n/6HbL25/8pGqF9BSOXsLVlFYKU7Rx Aaii7Z6qopfURgiOv/88rspUZ0KsOydl2c4I/yesiBlmXy2g4/4pr5StxxMZBrdCbS8u 4l2Zo48zF/bM9/Y51rwAYDt8n08yHQzkoJ0/u2c3rULguc9tZQZwryHw9PXw4+VqiHR4 bWtxPI/pIBz31ueQM/4usDh5E3VFRoNgT80NCfuNZpcYYCq8AburNcm7694/+qotDW4W cvogeOcXTvNT8b5hueAPHcbhVS1T6OvrWiyupnbImygsGFy4/MH7fFLpiLOib7MENLE2 qXGw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding :content-language; bh=5bc4aQZV9+RC9cNFh5PGe4YpDiNQfISK0JHpOJkMnXk=; b=pkjjGcwiIBdjiFB24Q9QO7bzb/4APjd4plBNADhQBsexX+xv7B5/b92Bn2q+BSPyPv 6awWD6hiC121HYr0xyFD8YUsEQk7wsaJPNnpc6wcKanv9LpOPhbK0ViJNny14S0QX2Y+ DeVWkQ5MjFkW7+emSg9lGSSYKzZVDZDrL1OYzosg6BO2YUoE5T1J0ZaC/C8CflfUlX2H mDP/7BGYSp9+JcPAdq2peacNr04t+L4H2ae/QSfGHkaJBP2BvskZEov6cemx7v+j05Ke a2SAfICjKmcmW2L2fHg4/N2ekYEaqMcgPpZYhuRXIgTEaw7q6jZecZgUn3m/mfBGfupF +0Ew== X-Gm-Message-State: APjAAAUBjLVq+eQtooDZVvoiN1dG2QulcY0fnwQPJg7fISTSbzdMte1t vNXN4dEBT546EofdE6Vq+ZUv/GYyiHU= X-Google-Smtp-Source: APXvYqyY2pDambUcw7+MR4lgLv4gApaijsMYpT34y0cc5QVGukjR8Q4XhE3d/QuQSBnXB2OmH5nIJQ== X-Received: by 2002:a9d:67d8:: with SMTP id c24mr2545734otn.190.1559319993140; Fri, 31 May 2019 09:26:33 -0700 (PDT) Received: from [192.168.1.10] (ip70-171-116-89.no.no.cox.net. [70.171.116.89]) by smtp.googlemail.com with ESMTPSA id r23sm2538511otg.49.2019.05.31.09.26.32 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 31 May 2019 09:26:32 -0700 (PDT) Subject: Re: Inherit Database - Table Permissions To: pgsql-general@lists.postgresql.org References: From: Ron Message-ID: <7df7c54f-fffd-3a84-f824-6c6221f29b9e@gmail.com> Date: Fri, 31 May 2019 11:26:31 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.6.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Content-Language: en-US List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 5/31/19 11:17 AM, Sathish Kumar wrote: > Hi Team, > > We have a database and keep creating new tables for the requirement. > > Every time we have to grant readonly permission to the new tables which > are created for the db user. Instead is there a way to inherit privileges. > Basically, we have a readonly user, who should run only select statements > on existing or nee tables. > > Can you help me on how to achieve it. Maybe granting default privileges is what you need. -- Angular momentum makes the world go 'round.