question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Can't Delete Database

See original GitHub issue

System information:

  • MacOS Mojave 10.14.6
  • DBeaver version 7.0.3.202004191823

Connection specification:

  • Postgres
  • SSH

Describe the problem you’re observing:

Since updating to version 7.0.3.202004191823, can’t delete a specific database. No matter what, I receive error message Can't delete object 'warehouse_labs' Reason: Cannot drop the currently open database. Switch to another database and try again (Note: enable 'Show all databases' option to see them).

In the old version, could just set another database active and delete any open tasks on this database, but new version seems to have removed option to set databases active. Instead can set other dbs as default, but this doesnt solve the problem. There are no open tasks of any kind.

This only seems to apply to one specific database, so implies new version won’t switch which database is active.

Steps to reproduce, if exist:

  1. Open connection
  2. Right click on database and click delete
  3. Await error message

Include any warning/errors/backtraces from the logs

Reason: Cannot drop the currently open database. Switch to another database and try again (Note: enable 'Show all databases' option to see them).

image

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:12

github_iconTop GitHub Comments

3reactions
zyrconium13commented, Dec 4, 2020

What if the database I want to delete is the last one (I have no other database to switch to). How do I delete that?

0reactions
Tectractcommented, Jan 22, 2022

I’m stuck here. I also can’t delete a database with dbeaver.

Cannot drop the currently open database.

I have no idea what to do.

  1. Remove the database from connection settings.

ok

  1. set some other database as a default in DB Navigator tree.

I don’t see any option for “default” connection. Where is that? I’m stuck here.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Cannot drop database because it is currently in use
Go to available databases section and select master. Then Try DROP DATABASE the_DB_name.
Read more >
sql server - Can't Delete Database - DBA Stack Exchange
We are using SQL Server 2008 [10.0.5500.0]. It won't let me go into DB settings or read from tables. I can't manually delete...
Read more >
Cannot drop the database because it is currently in use
To fix the error 3702 cannot drop the database because it is currently in use with SQL Server. Check and close all the...
Read more >
How To Fix Access You Can't Delete The Database Object ...
Go to the Navigation Pane, choose the database object from which you want to delete. Hit the Database Tools tab, and then from...
Read more >
Delete a Database - SQL Server | Microsoft Learn
Expand Databases, right-click the database to delete, and then click Delete. Confirm the correct database is selected, and then click OK. Using ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found