What is the difference between mysql_fetch_array and
mysql_fetch_object?

Answers were Sorted based on User's Feedback



What is the difference between mysql_fetch_array and mysql_fetch_object?..

Answer / subrat

mysql_fetch_array ? Fetch a result row as an associative
ARRAY, a numeric array, or both
mysql_fetch_object ? Fetch a result row as an OBJECT

Is This Answer Correct ?    25 Yes 2 No

What is the difference between mysql_fetch_array and mysql_fetch_object?..

Answer / sumit

mysql_fetch_object : will return the results from database
as objects. fields will be accessible like an objects
i.e $result->name

mysql_fetch_array : will return the results from database as
array. fields will be accessible like in objects
i.e $result[name]

Is This Answer Correct ?    5 Yes 1 No

What is the difference between mysql_fetch_array and mysql_fetch_object?..

Answer / jeevabala

mysql_fetch_array : fetch the result as an array
mysql_fetch_object : fetch the result as a object

Is This Answer Correct ?    1 Yes 0 No

What is the difference between mysql_fetch_array and mysql_fetch_object?..

Answer / abhay kumar

mysql_fetch_array display all matching record from table as
an array while mysql_fetch_object dispaly first matching
from table as ab object

Is This Answer Correct ?    6 Yes 9 No

Post New Answer

More MySQL Interview Questions

How do you know the version of your mysql server?

0 Answers  


How do I create a mysql username and password?

0 Answers  


How do I change global variables in mysql?

0 Answers  


Is mysql connect deprecated?

0 Answers  


What are aggregate functions in mysql?

1 Answers  






What is row level locking?

0 Answers  


What does tinyint mean?

0 Answers  


What is difference between group by and order by clause?

0 Answers  


What is data directory in mysql?

0 Answers  


What is the storage engine used for MySQL?

1 Answers  


How do I change a procedure in mysql?

0 Answers  


please give me the answer for this: query which generates the second highest integer in the table?

8 Answers  


Categories