General information
Category:
Databases,Tables, Views, Indexing and SQL syntax
Hello,
If you have only one table you can use the statement Trey Walpole suggested.
If you have two tables e.g. customers and orders then you have to make a relation form the order table to the customer table to get the names.
SELECT customer.name, SUM(orders.balance) AS balance_sum ;
FROM orders;
INNER JOIN customers;
ON customer.customerID = orders.customerID;
GROUP BY 1;
INTO .....
Hope this works,
KW
PS. Sorry for responding so late, but i'm new on this site and still finding handy things on the UT everyday.
Previous
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only