MySQL Forums
Forum List  »  PHP

Re: Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource
Posted by: Vijayakumar R
Date: May 12, 2008 06:39AM

For connecting to a mysql database, three functions to be used,

mysql_connect(hostName, userName, Password);
mysql_select_db(databaseName);
mysql_query(Query);

In your code,

some time you have used only two of the above functions. You have to use all the three functions in the same order

At line number 69, add this line above the mysql_query function

mysql_select_db('databaseName');

Options: ReplyQuote


Subject
Written By
Posted
Re: Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource
May 12, 2008 06:39AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.