Results 1 to 4 of 4
Here is the error code:
Code:
Warning: mysql_select_db(): 5 is not a valid MySQL-Link resource in /data1/www1.ourlinux.net/bbs/sources/Drivers/mySQL.php on line 68
ERROR: Cannot find database ourlinux_net
Warning: mysql_query(): 5 is not ...
- 02-02-2005 #1Linux Newbie
- Join Date
- Aug 2004
- Location
- Houston Texas
- Posts
- 192
mysql couldn't find the database?
Here is the error code:
The strange thing is once we refresh the browser, it will work and the error message's gone.Code:Warning: mysql_select_db(): 5 is not a valid MySQL-Link resource in /data1/www1.ourlinux.net/bbs/sources/Drivers/mySQL.php on line 68 ERROR: Cannot find database ourlinux_net Warning: mysql_query(): 5 is not a valid MySQL-Link resource in /data1/www1.ourlinux.net/bbs/sources/Drivers/mySQL.php on line 101 Warning: mysql_error(): 5 is not a valid MySQL-Link resource in /data1/www1.ourlinux.net/bbs/sources/Drivers/mySQL.php on line 313
- 02-02-2005 #2Linux Guru
- Join Date
- Apr 2003
- Location
- London, UK
- Posts
- 3,284
Re: mysql couldn't find the database?
The most important part of the error is this:
Check that your connection to the server was successful when calling mysql_connect(), eg, by using the "or die()" check, eg:Warning: mysql_select_db(): 5 is not a valid MySQL-Link resource
$conn = mysql_connect("hostname", "username", "password") or die("Failed to connect to database");
- 02-02-2005 #3Linux Newbie
- Join Date
- Aug 2004
- Location
- Houston Texas
- Posts
- 192
Thanx jason. :P
I will exame that. But I also have this question, if it is not connecting to the database howcome after we refresh the webpage it will work?
- 02-02-2005 #4Linux Newbie
- Join Date
- Aug 2004
- Location
- Houston Texas
- Posts
- 192
What the ...Code:mySQL query error: SELECT t.*, f.topic_mm_id, f.name as forum_name, f.quick_reply, f.id as forum_id, f.read_perms, f.reply_perms, f.parent_id, f.use_html, f.start_perms, f.allow_poll, f.password, f.posts as forum_posts, f.topics as forum_topics, f.upload_perms, f.show_rules, f.rules_text, f.rules_title, c.name as cat_name, c.id as cat_id FROM ipbtopics t, ipbforums f , ipbcategories c WHERE t.tid=336 and f.id = t.forum_id and f.category=c.id mySQL error: mySQL error code: Date: Thursday 03rd of February 2005 01:30:48 AM


Reply With Quote
