Ask the SQL query question. please come in with jordan102 as you did yesterday! I used select * fromuser_listwhereuser_idin (883985, 883987, 802928, 802929). The query result contains only one row of returned values, not four rows. Have you tested the SQL statement in the php environment, thank you for asking the SQL query question about the query results under the command line. please come in with jordan102 as we did yesterday!
I use select * from user_list where user_id in (883985,883987, 802928,802929 );
The query results only return values in one row, not four rows. Have you tested this SQL statement in the php environment? thank you!
Query results under the command line
========================================================== ==================================
| 802928 | fnms | NULL | none of you |
| 802929 | xwei | NULL | |
| 883985 | gggef | NULL | gggef |
| 883987 | eeett | NULL | eeett |
On the php page
$ Newsql = "select * from user_list where user_id in (883985, 883987, 802928, 802929 )";
$ RsList = mysqli_query ($ conn, $ newsql)
While ($ row = mysqli_fetch_array ($ rsList ))
{
Echo"
------------- User_id: ". $ row [" user_id "];
}
The following is the result.
========================================================== ========================================================== ============
------------- User_id: 802928
------ Solution --------------------
Run the SQL statement in the command line or phpmyadmin. check whether the result is correct.