[wp-trac] [WordPress Trac] #16065: Move db_select statement in wp-db.php 5 lines

WordPress Trac wp-trac at lists.automattic.com
Sun Jan 2 12:46:41 UTC 2011


#16065: Move db_select statement in wp-db.php 5 lines
-------------------------+-----------------------------
 Reporter:  rohdef       |      Owner:
     Type:  enhancement  |     Status:  new
 Priority:  normal       |  Milestone:  Awaiting Review
Component:  General      |    Version:  3.1
 Severity:  normal       |   Keywords:
-------------------------+-----------------------------
 in the function db_connect() we have the following lines:

                 $this->set_charset( $this->dbh );

                 $this->ready = true;

                 $this->select( $this->dbname, $this->dbh );

 changing them to:

                 $this->select( $this->dbname, $this->dbh );

                 $this->set_charset( $this->dbh );

                 $this->ready = true;

 would be a major help for people implementing other databases than mysql,
 since some databases require the name om the database to be part of the
 connection string. Eg. the PG4WP plugin only create a fake connection on
 the connect command and waits for the select database statement to be run.

 I know it's in the details department, but for some of us it's an very
 important detail.

 Ps. PostgreSQL support would really be appreciated. Apart from being
 outdated at the moment the PG4WP creates a really nice start for giving
 adding support for other database vendors.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/16065>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list