Few things, always do this:
$result = mysql_query (" your query here ") or die (mysql_error());
So you can see errors from MySQL.
Resource IDs are simply pointers to information stored by PHP. So each Resource ID has a certain type and can be accessed by a certain type of function. In your case, the Resource ID #6 is a result set that MySQL returned, and you can access it with mysql_fetch_array, mysql_fetch_row, etc. It's probably easier to access it with mysql_fetch_array...
Also, remember that mysql_fetch_row returns an ARRAY, and not a STRING, so you can't just echo() the array. You need to echo the array elements, like dis:
echo ($my_array[0]);
echo ($my_array[1]);