MS Query in Excel

  • Thread starter Thread starter Peter
  • Start date Start date
P

Peter

I am new to SQL and using MS Query in Excel to extract
data from SQL Server.

The query retrives result from a number of tables and the
result is in the following format:

Card Number, Paid Date, Fee Paid, Total Fee Paid
1234, 23-11-2002, $20, $50
1234, 28-10-2003, $30, $50
1235, 10-10-2002, $20, $40
1235, 10-10-2003, $20, $40

Is there any way (like filtering / hiding column) to get
the following result:

Card Number, Total Fee Paid
1234, $50
1235, $40

Thanks
 
...
I am new to SQL and using MS Query in Excel to extract
data from SQL Server.

The query retrives result from a number of tables and the
result is in the following format:

Card Number, Paid Date, Fee Paid, Total Fee Paid
1234, 23-11-2002, $20, $50
1234, 28-10-2003, $30, $50
1235, 10-10-2002, $20, $40
1235, 10-10-2003, $20, $40

Is there any way (like filtering / hiding column) to get
the following result:

Card Number, Total Fee Paid
1234, $50
1235, $40


SELECT DISTINCT
[Card Number], [Total Fee Paid]
FROM MyTable

--
 
Back
Top