for this to work, the orders table would need to have a column to associate the the order to the user. on the eCart support page, there is a tutorial for adding registration to the eCart checkout process that walks through this.
This tutorial also ties into the Creating a download center tutorial.
the download count column would need to be in the orderdetails table.
when following the download center tutorial, you will need to add another hidden element to the download form, and set it to use the DetailID column. in the download behavior, set the download count section to use the orderdetail table, set the Key Column to the DetailID, and for the key value select the hidden form element that was created
now a join query can be used to track downloads by user by the user session ID and the sum function, for example
SELECT SUM(orderdetails.downloadCount) userDownloads
INNER JOIN orders
ON users.userID = orders.OrderUserID
INNER JOIN orderdetails
ON orders.OrderID = orderdetails.DetailOrderID
WHERE orders.orderUserID = 1
this example assumes the count column in the order details table is named "downloadCount"
or to track download by product:
SELECT SUM(orderdetails.downloadCount) totalDownloads
INNER JOIN products
ON products.productID = orderdetails.DetailProductID
WHERE orderdetails.DetailProductID = 1