ExamVeda
Login
Home
This question belongs to MySQL MySQL Miscellaneous
MySQL Miscellaneous
?

What returns a string containing an error message?

Answer & Solution
Correct Answer: Option A
This question asks about a function in MySQL that provides information about errors that occur during database operations.
Let's understand the options:
Option A: mysql_error()
This function returns a string containing the actual error message.
Option B: mysql_errno()
This function returns an integer representing the error number.
Option C: mysql_sqlstate()
This function returns a five-character SQLSTATE error code.
Option D: mysql_close()
This function closes a database connection and doesn't return an error message.
Therefore, the correct answer is Option A: mysql_error() because it specifically returns the error message as a string.
Examveda
Question posted by Examveda
Community

Join the Discussion

No comments yet Be the first to discuss this question.