0

how can i delete the database that i am in it in mysql? without knowing the name of the database

DROP DATABASE()
1
  • You asked this stackoverflow.com/questions/62363389/… You are not going to get any different answers by reposting the same question.You might try expanding the question to explain why you would not know or cannot acquire the db name, Commented Jun 14, 2020 at 7:16

2 Answers 2

2

You can first find the name of current dbname as follow code.

SELECT database()

With this query you'll get the current db name. And after that, just say;

DROP DATABASE databaseName
Sign up to request clarification or add additional context in comments.

1 Comment

You might run into an issue trying to drop the database you are currently connected to.
0

I think it's not possible to drop a database without a name.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.