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 is the difference between mysql_fetch_object and
mysql_fetch_array?

Answer Posted / arumugam

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

mysql_fetch_array : will return the results from database as
an array.The array will be in in associative as well as
numeric manner.
i.e $result['column_name'] or $result[0].here '0'indicates
first column in table

Is This Answer Correct ?    47 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is age a variable in research?

844


Suppose the variable $var1 is set to 10 and the $var2 is set to the character var1, what's the value of $$var2?

904


How to create an empty array in php?

1036


What are the popular frameworks in php?

914


What is the use of post in php?

927


How are php sessions stored?

920


What the use of var_dump()?

987


What is the purpose of the '.frm' file extension? What do thes file contain?

920


How to add 301 redirects in PHP?

856


How many types of errors in php?

996


How do you check if an arraylist is empty?

921


Why many companies are switching their current business language to php? Where php basically used?

884


What is difference between rest and http?

946


What is sql injection in php?

1059


What is meant by urlencode and urldecode?

1037