This maybe an old chessnut to you old sweats but I am a newbie to this.. I getting this error:-
mysql_fetch_array(): supplied argument is not a valid MySQL result resource in C:\wamp\www\dsg\Mytest.php on line 9
the database is called Camsdb
the table is called DBF
the fields of which there are three
1) refid
2)Datfd
3)Datfd2
the database connects but if fails on line 9
This is the code:
<?php
$con = mysql_connect("192.168.10.6","trevor","trevor");
if (!$con)
{
die('Could not connect: ' . mysql_error());
}
mysql_select_db("Camsdb", $con);
$result = mysql_query("SELECT * FROM DBF");
while($row = mysql_fetch_array($result));
{
echo $row['Datfd'] . " " . $row['Datfd2'];
echo "<br />";
}
mysql_close($con);
?>
Can someone help me as I am a real nubie to this connection lark
Regards Trevor