Here is my query, it works as coded, but it's not exactly what I am looking for output wise.
<?php
$result = mysql_query("SELECT racesforweek.racetype, racesforweek.racename, dynamicactivehorse.tOwner, left(Entries.RaceID, 4) As Race1, RIGHT(Entries.RaceID, 4) As Race2, Entries.HorseID, entries.Odds, retired.HorseName
FROM (dynamicactivehorse INNER JOIN (retired INNER JOIN Entries ON retired.ID = Entries.RealHorseID) ON dynamicactivehorse.dHorseID = Entries.HorseID) INNER JOIN playerschanging ON dynamicactivehorse.tOwner = playerschanging.pc_name
INNER JOIN racesforweek ON entries.raceid = racesforweek.racenum
WHERE entries.RaceID LIKE '$currentweek%' AND playerschanging.pc_Residency = 'nwrc' AND
(racesforweek.racetype = 'G3' OR
racesforweek.racetype = 'G2' OR
racesforweek.racetype = 'G1' OR
racesforweek.racetype = 'ST')",$sim)
or die(mysql_error());
while($row = mysql_fetch_array($result))
{
echo "<tr>";
echo "<td>{$row}.{$row}</td>";
echo "<td>{$row}</td>";
echo "<td>{$row}</td>";
echo "<td>{$row}</td>";
echo "<td>{$row}</td>";
echo "<td>{$row}</td>";
echo "</tr>";
}
?>
It outputs something like this...
1234.1111 Person 1
1234.2222 Person 2
1234.1111 Person 3
1234.2222 Person 4
The output I would like is this...
1234.1111
Person 1
Person 3
1234.2222
Person 2
Person 4
Can someone point me in the right direction?
Thanks in advance for any assistance provided!!