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...

Which is the best method to fetch the data from mysql?
1.mysql_fetch_array()
2.mysql_fetch_object()
3.mysql_fetch_row()
4.mysql_fetch_assoc()

Answer Posted / pradeep

hi all,

i think mysql_fetch_object or mysql_fetch_array both are best method bcz both are take same time for result show.

but mysql_fetch_array() fetches the records using the numeric index (as numbers) or using the string index (as column)

mysql_fetch_object() fetches the records as the object.
ex. $record->id;

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is a composer?

915


How to fix "headers already sent" error in php

1006


What is a lambda function in php?

1047


What is the use of is_array() and in_array()?

972


Is php coding easy?

912


Is it possible to destroy a cookie?

942


What is prepare in php?

971


Tell me what should we do to be able to export data into an excel file?

914


How to split a string into array using php?

1098


Tell me which programming language does php resemble to?

887


Define soundex()?

890


What is strcmp () in php?

928


Is array a key php?

922


What is basename php?

926


What is difference between get and post in php?

1099