the following code can't take my data from database. what could be the problem. here's the sample code:
mysql_connect('localhost','root','1234') or die("Unable to connect to MySQL");
mysql_select_db(mris) or die("Unable to select a database");
$query = "select mrisno,mdate from mrishead where mdate<'$datestart' and status='Approved' and appname<>'' and lastupdate>='$datestart'"
$result = mysql_query($query) or die("Error in query");
There's seems to be no problem or error message. when i try to replace $row['mrisno'] with $row it works well. But i want it to be a fieldname not a number for me not to have a hard coding but this isn't working. what seems to be the problem? thank you in advance for any information guys..