Help with SQL statement - Thanks

Поиск
Список
Период
Сортировка
От Henry
Тема Help with SQL statement - Thanks
Дата
Msg-id fR047.109239$HJ1.3093152@e3500-atl1.usenetserver.com
обсуждение исходный текст
Список pgsql-sql
There is a table called "Payments" which records every payment that a
company has received:

CustomerNo     Date    Amount
----------------------------------------
3214                2/12    30
3214                4/10    50
9943                4/18    40
9943                5/10    30
9943                2/13    70
1121                5/23    10
1121                4/20    40
1121                3/12    30
(more data...)


I want to be able to pull out the last payment made by everyone in a query:

CustomerNo     Date    Amount
---------------------------------------
3214                4/10    50
9943                5/10    30
1121                5/23    10
(other users...)

How should I write the SQL statement? Please email to me at
henry_lu@hotmail.com. Thank you very much.

Henry





В списке pgsql-sql по дате отправления:

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: Hey! ORDER BY in VIEWS?
Следующее
От: Mathew White
Дата:
Сообщение: Re: SQL - histogram