Jump to content

Found an entry in the 'db' table with empty database name; Skipped


Recommended Posts

Hello there,

 

I would be really grateful if someone could advice please, how do I find this pesky entry in the 'db' table? This is what it says,

 

"Found an entry in the 'db' table with empty database name; Skipped." MySQL version is 5.5.40

 

I am pretty much stuck on it. Does it mean the table's name is db? Plus, I am not sure I understand the wording of it too. The empty database name cannot exist by default as it won't allow you to create a database without a name in the first place. I do not even know how and where to begin to look for it because honestly speaking I do not quite understand the phrase itself, because it does not make much sense to me. I would really highly appreciate it if someone could explain and suggest how do I find the... "whatever it says" :-) and to fix it. Many thanks in advance!

 

P.S. I know this warning may easily and safely be ignored as it is of minor inconvenience and not that important the more so as MySQL is working fine but my curiosity is just running wild for two reasons: 1. I do not really understand what this warning message is trying to tell me and 2. How do I find and adjust it to turn off the warning.

 

Simple regular things as running myisamchk -r *.MYI on where MySQL is did not help as this warning is actually out of scope of what myisamchk can fix.

 

And yes, I've Googled it long enough but couldn't seem to come up with anything reasonable solutions.

 

Thankful for any suggestions / pointers / assistance / comments at all.

Edited by Klaipedaville

you could try running this query and see if there is an empty schema name

$sql = "SELECT
            SCHEMA_NAME
          , DEFAULT_CHARACTER_SET_NAME
          , DEFAULT_COLLATION_NAME   
        FROM information_schema.schemata";

 

 

This is what I get:

 

Failed to execute SQL : SQL $sql = "SELECT SCHEMA_NAME , DEFAULT_CHARACTER_SET_NAME , DEFAULT_COLLATION_NAME FROM information_schema.schemata"; failed : You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '$sql = "SELECT SCHEMA_NAME , DEFAULT_CHARACTER_SET_NAME ' at line 1

Yes, this one worked, thanks! I was pretty close to it testing all types of input.

 

However, running this command gave me just my databases list. I can easily see them without running any queries. What I am supposed to see / look for in this list of my databases after the command in question has been executed?

It was to enable you to view the raw data held by MySQL to try and locate the blank name. Do you have another database on your server with a table named "DB" which might have the offending blank name?

I see. Thank you for your input. Well, that's where the point was. I did not really understand what this warning message was saying and what I was supposed to look for. Now that's a bit clearer but still not clear enough. The 'db' as per this warning message is actually the name of a table? database? filed? or is it just some term in general that implies database = db?

 

I went through every single database and almost every single field manually and I found one table named 'db'. Please, note it's not nameless as the warning says (if I am not mistaken), it's just its name is db. Do you think I could simply re-name that table to make this warning disappear? On the other hand is it possible to rename an existing table at all? I am not really sure as I do not see any options to re-name it. Perhaps there are some manual tricks to re-name tables aren't there?

as I was saying I found the table named db manually... not sure if it's the only one db in there. Were there by any chances any queries to run to find the problematic 'db' (whatever that stands for) as per warning message?

 

 

"Found an entry in the 'db' table with empty database name; Skipped."

 

It sounds like the problem is with an empty value in one of the records inside that "db" table

Now that is what I was looking for. Thank you. Now I at least I understand what this warning has been trying to say.

 

Could you please, take a look at the screen-shot attached to tell me if I am on the right track here? Many thanks!

 

Appreciate you taking part and your quick replies!

post-173373-0-13554400-1414656873_thumb.jpg

That is a screenshot of the table structure (and looks correct). You should be looking at the data in that table to see if there really is one with a blank database name.

Edited by Barand

Right! You are the man! Thank you very much! There was indeed one nameless 'database name' but it did not have any names at all in fact it said 'Any' in a Database Name column. Now I've remembered setting it myself thinking that if I set it to 'any' (there is an option to choose to set it to 'any') it will allow connection to any databases for this user. It appears to be I was wrong and setting it to 'any' just results in a warning message. I have now fixed it.

 

Although there are  two more warnings copy-pasted down below but I don't think they are related to my data or anything aren't they? I guess they have something to do with my MySQL version (5.5.40) and simply tell me that these issues will be removed in the future releases. Is that not right is it?

 

[Warning] Using unique option prefix key_buffer instead of key_buffer_size is deprecated and will be removed in a future release. Please use the full name instead.
 

[Warning] Using unique option prefix myisam-recover instead of myisam-recover-options is deprecated and will be removed in a future release. Please use the full name instead.

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.