|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2009-12-20 13:16 UTC] rasmus@php.net
[2009-12-20 20:38 UTC] svn@php.net
[2009-12-20 20:38 UTC] degeberg@php.net
[2020-02-07 06:09 UTC] phpdocbot@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2026 The PHP GroupAll rights reserved. |
Last updated: Sat May 16 14:00:01 2026 UTC |
Description: ------------ Where is mysql_select_db ? Reproduce code: --------------- --- From manual page: function.mysql-result#23 --- <?php $link = mysql_connect('localhost', 'mysql_user', 'mysql_password'); if (!$link) { die('Could not connect: ' . mysql_error()); } $result = mysql_query('SELECT name FROM work.employee'); /*Added by USER*/ mysql_select_db('test'); /**************/ if (!$result) { die('Could not query:' . mysql_error()); } echo mysql_result($result, 2); // outputs third employee's name mysql_close($link); ?> Expected result: ---------------- Christoper Lamm // this is just example.. Actual result: -------------- Could not query:No database selected