0

我有一张这样的桌子:

name1      | name2  | value1
-------------------------
Apple      | asdg   | 100
Apple      | ghf    |  50
Lemon      | dhjhgf |  60
Meat       | iop    | 300
Meat       | pdjs   |  70
Meat       | ncm    |  10
Strawberry | jdksa  |  20

我应该怎么做才能得到这个:

name1      | name2  | value1
----------------------------
Apple      | asdg   | 100
Lemon      | dhjhgf |  60
Meat       | iop    | 300
Strawberry | jdksa  |  20
4

1 回答 1

0

Access实际上First在查询中具有功能,这很容易:

SELECT name1, First(name2) AS name2, First(value1) AS value1 FROM TheFruitTable GROUP BY name1

于 2013-03-01T12:46:33.377 回答