DEV Community

Imelda
Imelda

Posted on

Having "permission denied" error while creating table in DBeavers using postgres?

Sometimes, while using postgres on DBeavers, postgres is usually the root user. Now let's assume you're just a user created by this root user and still are not able to create your own table, you can find your way by creating your own schema.

Just type as your first line of code:

CREATE SCHEMA <schema_name>
Enter fullscreen mode Exit fullscreen mode

Then go ahead to create your table.

Note: while

CREATE TABLE <schema_name>.<table_name>
Enter fullscreen mode Exit fullscreen mode

Creates a table in that particular schema,

CREATE TABLE <table_name>
Enter fullscreen mode Exit fullscreen mode

Creates a table in the public schema.

Either way works. Good luck.

Please leave a feedback if this helps you.

Top comments (0)

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay