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 1hNjc3-0004WA-DM for pgsql-sql@arkaria.postgresql.org; Mon, 06 May 2019 19:49:23 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1hNjc2-0001eu-3U for pgsql-sql@arkaria.postgresql.org; Mon, 06 May 2019 19:49:22 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hNjc1-0001bY-L0 for pgsql-sql@lists.postgresql.org; Mon, 06 May 2019 19:49:21 +0000 Received: from mail-pl1-x643.google.com ([2607:f8b0:4864:20::643]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hNjbz-00056g-0A for pgsql-sql@lists.postgresql.org; Mon, 06 May 2019 19:49:20 +0000 Received: by mail-pl1-x643.google.com with SMTP id d3so2868861plj.11 for ; Mon, 06 May 2019 12:49:18 -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-language; bh=XDLTZymKkHcVcFl1XnNmd30kJwCmuexrTEdgHvA3+mc=; b=DCNwVkhsYk5rPGHngGiYXPtEbFTsNCW0DcHu1ETnRX0KZRfPm6tJRTMulgQRi4lOvG fA3LuQQe7TtN6HGq0AmVw2XM5tgXfrPm32s11KEH+y4cYb15F8hY0M0ulVKDYH/PaQIY AL6drZ/xMDLxIMw2R1aJfQ0WdKQRSQNur31oT5Hz4Ym5lHdJuBlkCnv2Dn0hiIerjYri ZWmy9sWoC43Fp02MjZnySVs3cAVY8quCnKp95hrixawv76a1GYEt17ekgYDA08M5yrXF J4x/BTuiIZt4RbyQBZpnqAhvpTvqUEWkUcfGCNB7h0Nu1lLdGXalb2vDNh9ECQHKHiFt Cyvw== 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-language; bh=XDLTZymKkHcVcFl1XnNmd30kJwCmuexrTEdgHvA3+mc=; b=YFJuCmPNLUw8K/SenXdgEfC+Q3gN8nRuKfLdSGqPSik2mWke1cSkWRuhyq/5cKwVrA Wjg83jOZsTs0PYpXlsfjHhMaeGfR0AaOdljxK9MQVyJC/yHR1w338HXZmfSmskV1/adC D1H4xfYIpC+Okl4djoiqEkIyJhagKYaL+P4HgE3ylESx5hrrSr5bIu4w5pPHDwlrzAjC /+RVRProxPWyNFGgidcMhq5n4oSnprBjn4y1oTbRuCmN0Folqcytw/nKWkyHJcKR1K9A C+9xJLzQba44pVpWQoTzMcPLo4JxiNLyAcTX4kTBClMBLYou02HkvUW7a3p76QUD5ptK dCtg== X-Gm-Message-State: APjAAAUOKkUktzFUtfWIGQCHOTK0IpuXORge5tS60Ro5ZG1N7/DGbeWM d9QqH9fIZ57PHzbnYX9XXGVGrTwR X-Google-Smtp-Source: APXvYqwUlQ3nMF3ubZyqUyYEKZ+W6wGKqwsKVz98qOzZGy0PQfWqmj3sI8a3jy4k26CnNVAt4Fqz4w== X-Received: by 2002:a17:902:820c:: with SMTP id x12mr33698658pln.199.1557172157540; Mon, 06 May 2019 12:49:17 -0700 (PDT) Received: from [10.104.134.41] ([155.100.47.1]) by smtp.gmail.com with ESMTPSA id c17sm14265074pfn.173.2019.05.06.12.49.16 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 06 May 2019 12:49:17 -0700 (PDT) Subject: Re: create role/user management To: pgsql-sql@lists.postgresql.org References: From: Rob Sargent Message-ID: <906879c8-8e04-d436-ad7b-63ff057b1abb@gmail.com> Date: Mon, 6 May 2019 13:49:15 -0600 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: multipart/alternative; boundary="------------6677FB9E4BCF53EF84538074" Content-Language: en-US List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk This is a multi-part message in MIME format. --------------6677FB9E4BCF53EF84538074 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit On 5/6/19 1:43 PM, David G. Johnston wrote: > On Sat, May 4, 2019 at 9:38 AM Kirti Adesara > wrote: > > I have a database with multiple tables, functions and triggers in > public schema. > > > You should stop using the public schema. > > I want to create a user that can login to database and select on > specific tables and cannot access to any functions, triggers and > specific tables. > > > Maybe provide an example what what is not presently working the way > you expect and describe how you would like it to work - after > refraining from using the public schema. > > David J. > And it's really easy to move a table to a different schema with "alter table" --------------6677FB9E4BCF53EF84538074 Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: 7bit


On 5/6/19 1:43 PM, David G. Johnston wrote:
On Sat, May 4, 2019 at 9:38 AM Kirti Adesara <kdadesara@hotmail.com> wrote:
I have a database with multiple tables, functions and triggers in public schema.

You should stop using the public schema.

I want to create a user that can login to database and select on specific tables and cannot access to any functions, triggers and specific tables.

Maybe provide an example what what is not presently working the way you expect and describe how you would like it to work - after refraining from using the public schema.

David J.

And it's really easy to move a table to a different schema with "alter table"
--------------6677FB9E4BCF53EF84538074--