V
V
Vasya Borisevich2018-05-15 18:53:43
MySQL
Vasya Borisevich, 2018-05-15 18:53:43

What will mysql_query(SELECT) return?

What is the value returned by the query from the database?

$que = mysql_query($link, "SELECT * FROM `logins` WHERE `login` = '".$name."'");

As I understand it, there will be no such "if a value is found then true, if not found then false".
Leafing through Google, I realized that such a request would return rows in a positive case, but I did not find more information, or I was looking for it well.
Help to decide what is returned from the request in case of success and failure.
Thanks in advance :)

Answer the question

In order to leave comments, you need to log in

1 answer(s)
M
Melkij, 2018-05-15
@ki11k4

In today's php7+ world - an error for calling an unknown function. Or whatever, if you made your own.
In the museum world, the result resource, or false on error.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question