Dashboard – this page shows sample data for a user with many linked accounts.  You are able to track your overall portfolio day by day, as well as the daily account, category, and symbol level breakdowns.

Net Worth

$10,998,373.98
Accounts (4)
Cash
Click "+" to link Cash accounts.
Investment
Charles Schwab
$6,346,770.47
Schwab Main - ending 6319
2024-04-22
Edward Jones - U.S. Clients Access
$206,493.15
Wells Fargo 529 - ending 6189
2024-04-22
Custom
+
Custom
$2,240,397.36
Wife 401k
2024-04-22
Custom
$2,204,713.00
Husband 401k
2024-04-22
select t.duser,t.sym "dim",t.txn_mon "col",t.sym_type,t.amt
      ,t2.days
      ,ROUND(((amt * 365 * -1) / greatest(30,t2.days)),2) "div_amt_yr"  # min 30 days, ie monthly. 
      ,p.value
      ,ROUND(((amt * 365 * -1) / greatest(30,t2.days)) / p.value,4) "metric"
      #,p.*
FROM
( # this is your driving table.  
        select dc(USER) "duser",sym,date_format(txn_date,'%Y-%m') "txn_mon",max(txn_date) "txn_date"
              ,max(sym_type) "sym_type",sum(amt) "amt",count(1) "div_days",group_concat(concat(amt,'|',txn_date)) "details"
              #,MAX(USER) "user",MAX(acct_name) "acct_name"
        # select id,inst,dc(acct_official_name),mask,sym,sym_type,amt,txn_date,txn_name,price,qty,txn_type,txn_subtype,ctype
        from msd_txns 
        WHERE 1=1
          AND ctype IN ('I') # only looking at income txns
          ###################################
          # adjust what you are looking for here
	  and user = 'kRLS4aSli2oug5rpwcaa2Q=='
          #and dc(USER) = 'travis@tisa.com'
          #AND mask = '8789'
          #AND sym <> '$$$'
          #AND sym = 'SNOXX'   
          AND (  (sym = '$$$')
              OR (lower(sym_name) like '%money market%' OR lower(sym_name) like '%money fund%' OR lower(sym_name) like '%money fd%')
              )
          #order by duser,inst,dacct_name,mask,sym,txn_date # used with select * only, else comment this line
        group by duser,sym,date_format(txn_date,'%Y-%m')
		  ORDER BY duser,sym,txn_mon 
) t
left JOIN 
(  # this levels shows all user/acct/syms and the days between dividends needed to calc a yearly figure.
	SELECT duser#,dacct_name,inst#,max(user) "user",max(acct_name) "acct_name"
		,sym
		,MIN(txn_date) "prev_div_date"
		,MAX(txn_date) "last_div_date"
		,datediff(MAX(txn_date),MIN(txn_date)) "days"
		# select * 
   FROM
	(
	  SELECT p.* 
	        ,ROW_NUMBER() OVER (
	         PARTITION BY duser,sym
	         ORDER BY txn_date DESC
	         ) "rank"  # rank these so we can grab the last 2
	  FROM (select dc(USER) "duser",sym,date_format(txn_date,'%Y-%m') "txn_mon",max(txn_date) "txn_date"
	              ,max(sym_type) "sym_type",sum(amt) "amt",count(1) "div_days",group_concat(concat(amt,'|',txn_date)) "details"
	        # select id,inst,dc(acct_official_name),mask,sym,sym_type,amt,txn_date,txn_name,price,qty,txn_type,txn_subtype,ctype
	        from msd_txns 
	        WHERE 1=1
	          AND ctype IN ('I') # only looking at income txns
	          ###################################
	          # adjust what you are looking for here
	          and user = 'kRLS4aSli2oug5rpwcaa2Q=='
	          #and dc(USER) = 'travis@tisa.com'
             AND (  (sym = '$$$')
                 OR (lower(sym_name) like '%money market%' OR lower(sym_name) like '%money fund%' OR lower(sym_name) like '%money fd%')
                 )
	          #AND sym <> '$$$'
	          #order by duser,inst,dacct_name,mask,sym,txn_date # used with select * only, else comment this line
	        group by duser,sym,date_format(txn_date,'%Y-%m')
			  ORDER BY duser,sym,txn_mon 
	       ) p                           
		    ###################################
		  #ORDER BY acct_name,mask,sym,txn_date
	) t
   WHERE RANK IN (1,2) # only grab the last div and the one before it
	GROUP BY duser,sym
	HAVING MIN(txn_date) <> MAX(txn_date) # has to have at least 2 dividends so we can establish a time period
	ORDER BY duser,sym
) t2 ON (t2.duser = t.duser AND t2.sym = t.sym)
left JOIN (SELECT USER,sym,txn_date,SUM(VALUE) "value"
           from msd_positions
           WHERE acct_type = 'investment'
           GROUP BY USER,sym,txn_date
           ) p ON (dc(p.user) = t.duser AND p.sym = t.sym AND p.txn_date = t.txn_date)
ORDER BY duser,dim,col

Created by investors. For investors.