Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


What are the differences between MySQL_fetch_array(),
MySQL_fetch_object(), MySQL_fetch_row()?

Answers were Sorted based on User's Feedback



What are the differences between MySQL_fetch_array(), MySQL_fetch_object(), MySQL_fetch_row()?..

Answer / amita

mysql_fetch_object will return result from database as
objects i.e. $result->name
mysql_fetch_array will fetch result row as an associative
array or numeric array or both with the help of mysql_NUM or
mysql_ASSOC option.
eg: $result[0] ,$result['name']
mysql_fetch_row will fetch result row as an numeric array.
eg: $result[0]

Is This Answer Correct ?    4 Yes 0 No

What are the differences between MySQL_fetch_array(), MySQL_fetch_object(), MySQL_fetch_row()?..

Answer / vel

when u r using mysql_fetch_object i will first matching
record.
u can access the result set by column name of that record.

when u r using mysql_fetch_array i will fetch all the
matching records from the table.
u can access the result set by index as well as colum name
of that record.

Is This Answer Correct ?    3 Yes 0 No

Post New Answer

More MySQL Interview Questions

Which is faster mongodb or mysql?

0 Answers  


how fastest access of data can be done from database ?

3 Answers  


Can we rename database in mysql?

0 Answers  


How do you create a primary key?

0 Answers  


What causes mysql too many connections?

0 Answers  


How to delete a trigger in mysql?

0 Answers  


How do I run mysql from command line?

0 Answers  


What are the advantages of myisam over innodb?

0 Answers  


How is data stored in mysql?

0 Answers  


What is insert query in mysql?

0 Answers  


What is mysqli_num?

0 Answers  


What is difference between mysql and mysql server?

0 Answers  


Categories