Possible Duplicate:
Merge two rows in SQL
I have the following values in table:
---------------------
row1 | row2 | row3
---------------------
val1 | |
| val2 |
| | val3
How do I merge these rows?
$qu = mysql_query("SELECT * FROM `table`");
while($row = msyql_fetch_assoc($qu)){
$rowone = $row['row1'];
$rowtwo = $row['row2'];
$rowtre = $row['row3'];
echo $rowone." ".$rowtwo." ".$rowtre;
}
I want this to return
val1 val2 val3
I have a theory about how this is possible but I was wondering if there is a more straightforward method.