37 $ret = mysql_query( $sql, $this->mConn );
39 $ret = mysql_unbuffered_query( $sql, $this->mConn );
52 # Otherwise we get a suppressed fatal error, which is very hard to track down
53 if ( !extension_loaded(
'mysql' ) ) {
56 "MySQL functions missing, have you compiled PHP with the --with-mysql option?\n"
61 if ( $this->mFlags &
DBO_SSL ) {
62 $connFlags |= MYSQL_CLIENT_SSL;
65 $connFlags |= MYSQL_CLIENT_COMPRESS;
68 if ( ini_get(
'mysql.connect_timeout' ) <= 3 ) {
76 for ( $i = 0; $i < $numAttempts && !$conn; $i++ ) {
81 $conn = mysql_pconnect( $realServer, $this->mUser, $this->mPassword, $connFlags );
83 # Create a new connection...
84 $conn = mysql_connect( $realServer, $this->mUser, $this->mPassword,
true, $connFlags );
96 if ( function_exists(
'mysql_set_charset' ) ) {
97 return mysql_set_charset( $charset, $this->mConn );
99 return $this->
query(
'SET NAMES ' . $charset, __METHOD__ );
107 return mysql_close( $this->mConn );
114 return mysql_insert_id( $this->mConn );
121 if ( $this->mConn ) {
122 return mysql_errno( $this->mConn );
124 return mysql_errno();
132 return mysql_affected_rows( $this->mConn );
140 $this->mDBname = $db;
142 return mysql_select_db( $db, $this->mConn );
149 return mysql_get_server_info( $this->mConn );
153 return mysql_free_result(
$res );
157 return mysql_fetch_object(
$res );
161 return mysql_fetch_array(
$res );
165 return mysql_num_rows(
$res );
169 return mysql_num_fields(
$res );
173 return mysql_fetch_field(
$res,
$n );
177 return mysql_field_name(
$res,
$n );
181 return mysql_field_type(
$res,
$n );
185 return mysql_data_seek(
$res, $row );
189 return ( $conn !==
null ) ? mysql_error( $conn ) : mysql_error();
193 return mysql_real_escape_string(
$s, $this->mConn );
197 return mysql_ping( $this->mConn );