Sorry, I understand what you mean now.
>>>Could you please include original message in your reply, so I can understand you? As I said, your requirement could be only done in 2 SQLs (a minimum, my original solution requires 3), if you do it in VFP or Access. My colleague told me, what in Oracle or SQL Server it could be done in 1, since they allow to have from as SELECt statement.