?
On failure, 'mysql_query()' returns . . . . . . . .
Answer & Solution
Correct Answer:
Option
D
This question is about how MySQL tells you if a query was successful or not.
The function `mysql_query()` is used to send SQL commands to the database.
When a command runs successfully, it returns a special value.
When something goes wrong, it returns a different value to signal an error.
The answer: Option C (-1).
So, if `mysql_query()` returns -1, it means your query failed.
The function `mysql_query()` is used to send SQL commands to the database.
When a command runs successfully, it returns a special value.
When something goes wrong, it returns a different value to signal an error.
The answer: Option C (-1).
So, if `mysql_query()` returns -1, it means your query failed.
Join the Discussion
Login to post a comment or share your explanation.
Login