Reputation
3,593
Top tag
Next privilege 5,000 Rep.
Approve tag wiki edits
Badges
3 13 23
Newest
 Marshal
Impact
~186k people reached

Apr
20
reviewed Close Stored procedure
Apr
20
reviewed Leave Closed Opinion on Database Design for Task
Apr
20
revised What is the risk of doing a rebuild to my indexes in sql server 2012?
deleted 23 characters in body; edited tags
Apr
20
reviewed Edit How to prevent misuse of rights in monitoring application?
Apr
20
revised How to prevent misuse of rights in monitoring application?
corrected spelling
Apr
20
reviewed Close complex SQL depending on each object insert time?
Apr
20
reviewed Close How to update a multiple rows all at once with a procedure.?
Apr
20
reviewed Leave Open percona cluster 5.6 - handshake with remote endpoint failed, but endpoint is not part of config
Apr
20
reviewed Reject Interpretation of multiple join order
Apr
20
reviewed Approve Use transaction logs multiple times
Apr
20
reviewed Approve When doing an update on a set of records, how do i get previous updates to show on current row to update in UDF
Apr
20
answered Running Total: To store or compute
Apr
20
comment Running Total: To store or compute
Still, an index on product_id, transaction_date and a query specifying product_id and a date range (or >= today) should give more than adequate performance.
Apr
20
revised RHEL 6: postmaster dead but pid file exists
deleted 22 characters in body
Apr
20
answered Re-import packages in Oracle
Apr
20
comment Running Total: To store or compute
With 10 transactions per product, it should be lightning fast to calculate this on the fly. Make sure you have an index on (or starting with) production_transaction.product_id so that you can quickly retrieve all transactions for a product.
Apr
20
comment Running Total: To store or compute
It depends. How many transactions do you expect per product? Computing on the fly is fast with suitable indexes. I would build like this to start with, and only add storage of running totals if it proves too slow. Test this in your Test / Q&A environment!
Apr
20
comment Running Total: To store or compute
MySQL. Not SQL Server.
Apr
20
reviewed Close Why is the transaction log file not truncated though its simple recovery model?
Apr
20
reviewed Leave Closed Mysql 5.6 very slow on windows server 2012 compared to other platforms