I am trying to create a stock portfolio tracker.
Table 1 has all transactions in this format: Date | Irrelevant | Amount Bought ( ) or Sold (-).
Table 2 has all Dates for every Day from the Date of the first purchase until the current Date.
I am trying to get a Formula that calculates the total amount of shares bought/sold on a given day. Table 2 should then look like this:
I have tried some array formulas but cant figure out how SUM all Amounts for a specific Date.
This is what I currently have:
=ArrayFormula(INDEX(Transactions!$B$12:D, MATCH (TRUE,EXACT(Transactions!$B$12:B, B7),0)))
I am thankful for any help!
CodePudding user response:
I believe this isn't really a proper question for stackoverflow, but try `=SUMIF(Transactions!$B$12:$B, B25, Transactions!$D$12:$D)' and just drag it down (or Ctrl D).