Me personally, I would do this in 2 queries. Not gonna write out all the code, just some pseudo-ish for you.
Code:
$result = mysql_query("SELECT date, tournament, position FROM tournaments WHERE name = '" . $_POST['golfer1'] . "'");
while ($golfer1 = mysql_fetch_array($result)) {
$date[1][] = $golfer1['date'];
$tournament[1][] = $golfer1['tournament'];
$position[1][] = $golfer1['position'];
}
$result = mysql_query("SELECT date, tournament, position FROM tournaments WHERE name = '" . $_POST['golfer2'] . "'");
while ($golfer2 = mysql_fetch_array($result)) {
$date[2][] = $golfer2['date'];
$tournament[2][] = $golfer2['tournament'];
$position[2][] = $golfer2['position'];
}
echo "<table><tr><td>Date></td><td>Tournament></td><td>" . $_POST['golfer1'] . "</td><td>" . $_POST['golfer2'] . "</td></tr>";
$i = 0;
while ($i < = count($date[1])) {
echo "<tr><td>" . $date[1][$i] . "</td><td>" . $tournament[1][$i] . "</td><td>" . $position[1][$i] . "</td><td>" . $position[2][$i] . "</td></tr>";
$i++;
}
echo "</table>";
Of course, this code won't work perfectly for you. It doesn't check to see if the two players played on the same date, same tourney, but that's a simple query change (I don't know the structure of your table).
I would probably omit the date and tourney from the seperate array returns and make it part of the query, change the while loop to run off of mysql_num_rows($result).
Actually, now that I think about it this could be done in one query easily... just assign the positions to arrays like I did $position[1][x] and $position[2][x] where x is a counter for the rows you are looping through.
Then do your echos in a while loop like I did above.
Bah, kind of rambling and not even sure if this is going to help. I'll post anyway, maybe it'll get your creative juices flowing and you can come up with something. I know what I would do, but it's hard to give an exact solution w/o seeing how the database is setup.