what is the difference between mysql_fetch_array() and
mysql_fetch_row()?
Answer Posted / guru
Mysql_fetch_array():
Mysql_fetch_array() returns row as an associative, numeric array or both based on parameters passed in it. Three types of parameters can be passed in mysql_fetch_array function.
1. MYSQL_BOTH - return both associative and numeric array
2. MYSQL_ASSOC - return associative array
3. MYSQL_NUM - return numeric array
Reference:http://www.phponwebsites.com/2014/03/php-mysql-fetch-array.html
Mysql_fetch_row():
It return row as numeric array. We can't use associative indices to retrieve data from mysql table using php.
Reference: http://www.phponwebsites.com/2014/03/php-mysql-fetch-row.html
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What is user defined function in php?
What is asort php?
What is the difference server side and browser side validation?
What is php data type?
Which is better php praogramming or cad/cam scope wise and also salaray wise?
Tell us what is the difference between session_unregister() and session_unset()?
What are the different ways to login to a remote server? Explain the me, advantages and disadvantages?
What are the three parts of an http request?
How come the code works, but does not for two-dimensional array of mine?
What is return in php function?
Can I learn php without knowing c?
What is in php 7?
How to strip whitespace (or other characters) from the beginning and end of a string?
What is use of mysqli_query in php?
what the new feature add in php 7.2?