cannot delete from view pg_replication_slots

In this article, we will see solution for the error “cannot delete from view pg_replication_slots”.

ERROR: cannot delete from view "pg_replication_slots" DETAIL: Views that do not select from a single table or view are not automatically updatable. HINT: To enable deleting from the view, provide an INSTEAD OF DELETE trigger or an unconditional ON DELETE DO INSTEAD rule.

cannot delete from view pg_replication_slots

Continue reading cannot delete from view pg_replication_slots

How to uninstall PostgreSQL from Ubuntu

In this article, we will see how to uninstall PostgreSQL from Ubuntu.

Important Note: I suggest you to take backup of your important PostgreSQL databases. Once we uninstall, all your PostgreSQL data will be lost.

1. Stop PostgreSQL server using below command.

sudo systemctl stop postgresql

Continue reading How to uninstall PostgreSQL from Ubuntu

ERROR: cannot drop schema because other objects depend on it

In this article, we are going to see the solution for “ERROR: cannot drop schema because other objects depend on it”.

drop schema james;

ERROR cannot drop schema because other objects depend on it

Reason:
So, if the schema is not empty and you want to remove the schema and its objects, you must use the CASCADE option.

Solution:
Continue reading ERROR: cannot drop schema because other objects depend on it