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 1jjyRm-0007GF-Uv for pgsql-general@arkaria.postgresql.org; Sat, 13 Jun 2020 05:11:15 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1jjyRl-0006bQ-S0 for pgsql-general@arkaria.postgresql.org; Sat, 13 Jun 2020 05:11:13 +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 1jjyRk-0006bI-VY for pgsql-general@lists.postgresql.org; Sat, 13 Jun 2020 05:11:13 +0000 Received: from wout3-smtp.messagingengine.com ([64.147.123.19]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jjyRd-0008CB-AB for pgsql-general@postgresql.org; Sat, 13 Jun 2020 05:11:12 +0000 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.west.internal (Postfix) with ESMTP id 1C4B031D; Sat, 13 Jun 2020 01:11:02 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute4.internal (MEProxy); Sat, 13 Jun 2020 01:11:02 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aklaver.com; h= subject:to:references:from:message-id:date:mime-version :in-reply-to:content-type:content-transfer-encoding; s=fm3; bh=I 8F20cMfabydPvwzp11f9sYs4oyG6BSiRQ+zFB9NAMM=; b=njHkgSPJrwihG6TAk mhCTwhkK9qMdtKOGg1oB7kk4AiHLG1QgXWFoufSbYl6ooP2aLfp9xz5rQazp67CO 95lgJTfb0uFpYNnO82zzGOTQpJbimMOJRvMK4Mabjzvg8jP10uSLstEFt5KSo5sl JVR+Smx2HqshkptzsGceGj/bxRSy6VA8OaHsymGebd6JKrU6q4YIumQkP4hNks5v 73i/2ZsYHSmfe1KwC6Dk2BpY6vStXujH0GvNs5W7GDnBoPNqNrzIweDeEIrIrD5s 3i5V+1yMHfebgPOk90MdC5ekuvK0kF7PDbBJQMXHkvcRZeoVWUfLm8hnTuWWY7KC bKeNw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm3; bh=I8F20cMfabydPvwzp11f9sYs4oyG6BSiRQ+zFB9NA MM=; b=pUN+u62RcqzS9rtm2qbDU8IErbKPIcfe9wLoiyFE3vXeJ0kAvvDUOIlrI MxUVsVQMarcJyH/023nUxoC36c4W+gVyqpycmG94GpOTJfBuS18TduLN8Co56LM7 PA0reYNXlFIawU5YWWXrbAAgBUcwZHE8oe/oS/tc75OHRFaOLLzQn3zHfiH1B5YE MIxUF+op3le96j++L4LnwOcCCRtpZxL+ztX8iHsoZ4Enx0EScm/d1rrg0ZVXpQOZ K8vrkUmulNby8ad6P3/O6zb2j4SXCah9R1jpZk6vBs3RcfkXni51OsFVvvxKXJYM KRvGuKHn/QQDN0uSgoLXEe1gSskjg== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduhedrudeivddgleduucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucenucfjughrpefuvfhfhffkffgfgggjtgfgsehtje ertddtfeejnecuhfhrohhmpeetughrihgrnhcumfhlrghvvghruceorggurhhirghnrdhk lhgrvhgvrhesrghklhgrvhgvrhdrtghomheqnecuggftrfgrthhtvghrnhepteejvdetff ejuedvleeifeefheeutdfhgfdvhffhhfekvdduveegvdejudefgfevnecukfhppeejhedr udejvddrhedrvdefudenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrih hlfhhrohhmpegrughrihgrnhdrkhhlrghvvghrsegrkhhlrghvvghrrdgtohhm X-ME-Proxy: Received: from [192.168.1.3] (75-172-5-231.tukw.qwest.net [75.172.5.231]) by mail.messagingengine.com (Postfix) with ESMTPA id 1328F30618C1; Sat, 13 Jun 2020 01:11:00 -0400 (EDT) Subject: Re: Fwd: not able to give usage access to public schema To: sekhar chandra , pgsql-general@postgresql.org References: From: Adrian Klaver Message-ID: Date: Fri, 12 Jun 2020 22:11:00 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.9.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 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 6/12/20 3:56 PM, sekhar chandra wrote: > I am not able to give usage permission to public schema. below are the > steps. > > > Logged in as super user > created a new user as user1 > grant usage on public to user1 Either the above is a cut and paste error or you got an error: grant usage on public to role_test ; ERROR: relation "public" does not exist grant usage on schema public to role_test ; GRANT SELECT rolname, has_schema_privilege('role_test', 'public', 'usage') from pg_roles where rolname = 'role_test'; rolname | has_schema_privilege -----------+---------------------- role_test | t > > command completed successfully , but verification statement showing he > doesnt have usage permission. > SELECT rolname, has_schema_privilege(rolname, 'public', 'usage') from > pg_roles; > > this is strage. what could go wrong. -- Adrian Klaver adrian.klaver@aklaver.com