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


Difference between mysql_connect and mysql_pconnect in php?

Answers were Sorted based on User's Feedback



Difference between mysql_connect and mysql_pconnect in php?..

Answer / md amanullah

mysql_connect opens a normal connections to mysql database.
mysql_pconnect opens a persistant connection i.e. if there
is any connection open in the script it will use that
connection not making a new connection each time. at very
high traffic enviornment mysql_connect provides better
performance.

Is This Answer Correct ?    11 Yes 1 No

Difference between mysql_connect and mysql_pconnect in php?..

Answer / aatit

The following are the differences -

- A new connection is established to the database by using
mysql_connect, where as mysql_pconnect opens a persistant
connection to the database.

- mysql_connect can be used to close the connection, where as
mysql_pconnect can not close the connection.

- Database is opened every time when the page is loaded by
mysql_connect. Whereas by using mysql_pconnect, database need
not be connected every time.

Is This Answer Correct ?    4 Yes 0 No

Post New Answer

More PHP Interview Questions

how much a fresher php programmer can earn in india

5 Answers  


what is output of echo 1< 2 and echo 1 >2

8 Answers   HCL, Navigators Software,


How do you sort an array in php?

0 Answers  


How do I install php?

0 Answers  


how can i disable multiple user in the same password in my website using any scripts

1 Answers  


Explain how we can get the number of elements in an array?

0 Answers  


What is difference between variable declaration and variable definition?

0 Answers  


Explain me what is the meaning of a persistent cookie?

0 Answers  


Which PHP function would you use to send an email?

0 Answers  


How to create and destroy cookies in php?

0 Answers  


Tell me what is the importance of "action" attribute in a html form?

0 Answers  


What is PHP?

8 Answers  


Categories