What is the difference between mysql_connect() and
mysql_pconnect()?

Answer Posted / sumit

In mysql_pconnect(), ‘p’ stands for persistance connection.

when connecting, the function would try to find a (persistent) connection that’s already open with the same host, username and password. If one is found, an identifier for it will be returned instead of opening a new connection.


mysql_connect() function, every time it is opening and closing the database connection.

Is This Answer Correct ?    5 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How do you insert a table?

679


What port is mysql running on?

672


What's the latest version of mysql?

740


What is a join? Explain the different types of mysql joins.

1009


Can you tell the reasons for selecting lamp(linux, apache, mysql, php) instead of any other combination of software programs, servers, and operating system?

684


How can you filter the duplicate data while retrieving records from the table?

673


Can we store videos in mysql database?

705


How do I disable mysql?

691


How can you change the name of any existing table by using the sql statement?

754


What is horizontally scalable?

725


Write a query to select all teams that won either 1, 3, 5 or 7 games.

1061


What is meant by sharding?

683


What are the mysql database files stored in system ?

746


Is mysql deprecated?

670


How to change a password for an existing user via mysqladmin?

752