我有一个 SELECT 语句,我在其中加入 2 个单独的表。
$result = mysql_query('SELECT * FROM (SELECT * FROM gslil0009) as table1 UNION SELECT * FROM (SELECT * FROM gslil0028) as table2' . ' ORDER BY lname');
while($row = mysql_fetch_array($result)) {
echo $row['fname'];
}
如何打印出该行来自哪个表?