I fixed the issue as below which worked for me . thanks for your quick help
test=# DROP OWNED BY amosserver_test;
DROP OWNED
test=# DROP OWNED BY amosuser_test;
DROP OWNED
test=# drop role amosserver_test;
DROP ROLE
test=# drop role amosuser_test;
DROP ROLE
test=#
From: David G. Johnston <david.g.johnston@gmail.com> Sent: Wednesday, April 22, 2020 6:51 PM To: Ashok kumar Mani <amani@accelaero.com> Cc: pgsql-admin@postgresql.org; pgsql-admin@lists.postgresql.org Subject: Re: need help
Information Security Email Alert: This email is from an EXTERNAL source. Please use caution when clicking on links or opening attachments from an unknown or suspicious sender. To report a suspected phishing email, Send us an Email on Servicedesk@accelaero.com
On Wed, Apr 22, 2020 at 7:45 AM Ashok kumar Mani <amani@accelaero.com> wrote:
Classification: Internal
Dear All
Could you please some one help on this below issue ? I could n;t able to find any meaning on this below?
test=# drop user amosuser_test;
ERROR: role "amosuser_test" cannot be dropped because some objects depend on it
A role cannot be removed if it is still referenced in any database of the cluster; an error will be raised if so. Before dropping the role, you must drop all the objects it owns (or reassign their ownership) and revoke any privileges the role has been granted on other objects. The REASSIGN OWNED and DROP OWNED commands can be useful for this purpose; see Section 21.4 for more discussion.