Comments on: MySQL Interview Questions: Wrong Answers Only https://www.percona.com/blog/mysql-interview-questions-wrong-answers-only/ Fri, 08 Dec 2023 18:37:34 +0000 hourly 1 https://wordpress.org/?v=6.5.2 By: Daniel Nichter https://www.percona.com/blog/mysql-interview-questions-wrong-answers-only/#comment-10974222 Fri, 08 Dec 2023 18:37:34 +0000 https://www.percona.com/blog/?p=92274#comment-10974222

Would you really be able to alter a 10T table?

Yes, it’s a recently solved problem:

]]>
By: Kedar Vaijanapurkar https://www.percona.com/blog/mysql-interview-questions-wrong-answers-only/#comment-10974221 Fri, 08 Dec 2023 07:14:11 +0000 https://www.percona.com/blog/?p=92274#comment-10974221 Hi “Art”,

As an interviewer I really like to understand the thought process more than the real answer. You know “love the journey more than the destination” thing 😉 it is sort of that. This gives us a picture of how much of a brainstorming the candidate can do.

Also, about “…if I actually want to join the organization I’m applying to. “, usually during an Interview, the interviewer might really pulling your nerves to test you, doing deliberate wrong counter arguments to get the better justification and so on. IMHO this is not really a good subject to base a decision.

About your response to Trivia question is not right. Here I’m playing with the word “Dual”.

MySQL has a single database object, which is actually double.
You can’t see either of them, yet you can query! What is that?
> “dual” is a table (object) but the meaning hints “double”
> you cannot see “dual” object by “show tables” or any other queries but you can query a “dual” table:

Finally, I’d share my blog about sql_generate_invisible_primary_key and its usefulness.

(BTW Art, I feel the comment is AI generated)

Thanks,
Kedar.

]]>
By: Art https://www.percona.com/blog/mysql-interview-questions-wrong-answers-only/#comment-10974220 Thu, 07 Dec 2023 08:40:55 +0000 https://www.percona.com/blog/?p=92274#comment-10974220 I can relate to answers 1 and 5 as I probably would have answered the exact same thing. As having been in the interview seats many times, whenever I get an open question like these two I tend to answer with a provocative answer. Normally this would lead to a discussion. Being a MySQL expert, I can leverage this discussion to determine if I actually want to join the organization I’m applying to. If the discussion is unsatisfactory I’ll simply decline the offer.

> MySQL has a single database object, which is actually double.
> You can’t see either of them, yet you can query! What is that?
I would say you are referring to the generated invisible primary key. If the sql_generate_invisible_primary_key is enabled, a table without a primary key will automagically have one created. This creates both an invisible column with an auto increment attached to it and an invisible primary key. This means you can’t see either of them, but you would be able to select a specific row (or rows) by querying this column explicitly.

]]>