#49086 [Opn->Bgs]: MySQLI Options page does not list defaults

From: Date: Mon, 16 Nov 2009 12:39:32 +0000
Subject: #49086 [Opn->Bgs]: MySQLI Options page does not list defaults
References: 1  Groups: php.doc.bugs 
Request: Send a blank email to doc-bugs+get-3183@lists.php.net to get a copy of this message
ID: 49086 Updated by: vrana@php.net Reported By: jarrod dot makin at heartinternet dot co dot uk -Status: Open +Status: Bogus Bug Type: Documentation problem PHP Version: Irrelevant New Comment: I can't see anything to document. Please open a new bug report with clearer description if you do. Previous Comments: ------------------------------------------------------------------------ [2009-08-03 18:47:12] carsten_sttgt at gmx dot de | '--with-mysql=shared,/usr' '--with-mysqli=shared,/usr/bin/mysql_config' | | Does "shared" translate to meaning libmysql, mysqlnd or neither? "--shared" means, that a shared extension is build (not a static) which must be loaded in php.ini with "extension=foo.so" A path e.g. ",/usr" after this keyword means, that libmysql is used. In this setup libmysql (libs and headers) is located at "/usr". Or the libmysql config can be retrieved from the tool "/usr/bin/mysql_config". BTW: How the MySQL extensions are build (mysqlnd/libmysql), you can see in phpinfo(). Regards, Carsten ------------------------------------------------------------------------ [2009-08-03 08:31:28] jarrod dot makin at heartinternet dot co dot uk That is very interesting. My configure line shown in phpinfo output contains the following '--with-mysql=shared,/usr' '--with-mysqli=shared,/usr/bin/mysql_config' Does "shared" translate to meaning libmysql, mysqlnd or neither? ------------------------------------------------------------------------ [2009-08-01 09:03:51] carsten_sttgt at gmx dot de | Does this mean that MySQLI will automatically try to read in a file | called my.cnf that's in the same directory as the php script? libmysql is reading the normal option files, like other mysql clients e.g. the mysql command line tool. The search paths for option files are defined during configure/compile of the mysql client lib (libmysql). With MYSQLI_READ_DEFAULT_FILE you can specify another option file then the default ones. | Are there any special parameters that can be placed in the my.cnf | to be used with MySQLI? See the answer from Niel. libmysql is reading the groups [client] and [mysql]. BTW: This is only working, if the PHP extensions mysql, mysqli or pdo_mysql are build with libmysql. It's not working if they are build with mysqlnd (silent ignored). Regards, Carsten ------------------------------------------------------------------------ [2009-07-29 02:29:45] niel dot archer at blueyonder dot co dot uk "Read options from named option file instead of my.cnf" is misleading. As far as I can tell, the extension does not load my.cnf (or my.ini on Windows) from any of the locations mentioned in the MySQL documentation. The options file is documented in the MySQL documentation http://dev.mysql.com/doc/refman/5.0/en/option-files.html The defaults appear to be: MYSQLI_OPT_LOCAL_INFILE false MYSQLI_READ_DEFAULT_FILE ''. MYSQLI_READ_DEFAULT_GROUP 'client'. ------------------------------------------------------------------------ [2009-07-28 08:18:49] jarrod dot makin at heartinternet dot co dot uk Description: ------------ The MySQLI options manual page lists various parameters: MYSQLI_OPT_CONNECT_TIMEOUT connection timeout in seconds MYSQLI_OPT_LOCAL_INFILE enable/disable use of LOAD LOCAL INFILE but doesn't state what the defaults are if you don't explicitly set them. MYSQLI_READ_DEFAULT_FILE Read options from named option file instead of my.cnf "Read options from named option file instead of my.cnf" is misleading to me. Does this mean that MySQLI will automatically try to read in a file called my.cnf that's in the same directory as the php script? Are there any special parameters that can be placed in the my.cnf to be used with MySQLI? There are very few examples of this functionality being used. Reproduce code: --------------- --- From manual page: mysqli.options --- ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=49086&edit=1

« previous php.doc.bugs (#3183) next »