Vidyalelo
MySQL · Q588

MySQL

Programming · MySQL · question 588

Q588

Which mode exists at both global level and session-specific level?

A.
sql_mode
Answer
B.
key_buffer_size
C.
server_mode
D.
query_mode

Answer: Option A

Solution

Answer: Option A
Solution:
This question is asking about a setting in MySQL that can be applied to the entire database server (global level) or just for a specific user's connection (session-specific level).
Let's look at the options:
Option A: sql_mode - This option controls how MySQL handles different types of SQL statements. It can be set globally for the whole server or for each individual user's session.
Option B: key_buffer_size - This option determines how much memory MySQL uses for indexing data. It's a global setting and doesn't have a session-specific equivalent.
Option C: server_mode - This option controls the features and behaviors of the MySQL server. It's a global setting and doesn't have a session-specific equivalent.
Option D: query_mode - There is no such setting in MySQL.
So, the correct answer is Option A: sql_mode.
Think of it like this: sql_mode acts like a rule book that can be applied to everyone (global) or just to a specific person (session).
Therefore, the correct answer is (A).