Go straight to the Balances section for:
$ bean-query trip.beancount 'SELECT date,account,payee,position WHERE narration ~ "for all"'date account payee position ---------- ------------------------- --------------- ------------ 2022-10-18 Expenses:Groceries:Alice Zehrs 21.79 CAD 2022-10-18 Expenses:Groceries:Bob Zehrs 21.79 CAD 2022-10-18 Expenses:Groceries:Carol Zehrs 21.79 CAD 2022-10-18 Expenses:Groceries:Dick Zehrs 21.79 CAD 2022-10-18 Expenses:Groceries:Eve Zehrs 21.79 CAD 2022-10-18 Income:Alice Zehrs -108.95 CAD 2022-10-18 Expenses:Groceries:Alice Costco 20.928 CAD 2022-10-18 Expenses:Groceries:Bob Costco 20.928 CAD 2022-10-18 Expenses:Groceries:Carol Costco 20.928 CAD 2022-10-18 Expenses:Groceries:Dick Costco 20.928 CAD 2022-10-18 Expenses:Groceries:Eve Costco 20.928 CAD 2022-10-18 Income:Dick Costco -104.64 CAD 2022-10-19 Expenses:Groceries:Alice Walmart 12.48 CAD 2022-10-19 Expenses:Groceries:Bob Walmart 12.48 CAD 2022-10-19 Expenses:Groceries:Carol Walmart 12.48 CAD 2022-10-19 Expenses:Groceries:Dick Walmart 12.48 CAD 2022-10-19 Expenses:Groceries:Eve Walmart 12.48 CAD 2022-10-19 Income:Eve Walmart -62.40 CAD 2022-10-19 Expenses:Cottage:Alice Airbnb 177.183 CAD 2022-10-19 Expenses:Cottage:Bob Airbnb 177.183 CAD 2022-10-19 Expenses:Cottage:Carol Airbnb 177.183 CAD 2022-10-19 Expenses:Cottage:Dick Airbnb 177.183 CAD 2022-10-19 Expenses:Cottage:Eve Airbnb 177.183 CAD 2022-10-19 Income:Dick Airbnb -885.915 CAD 2022-10-20 Expenses:ParkPermit:Alice Provincial Park 4.20 CAD 2022-10-20 Expenses:ParkPermit:Bob Provincial Park 4.20 CAD 2022-10-20 Expenses:ParkPermit:Carol Provincial Park 4.20 CAD 2022-10-20 Expenses:ParkPermit:Dick Provincial Park 4.20 CAD 2022-10-20 Expenses:ParkPermit:Eve Provincial Park 4.20 CAD 2022-10-20 Income:Bob Provincial Park -21.00 CAD 2022-10-21 Expenses:Gas:Alice Gas stations 52.21 CAD 2022-10-21 Expenses:Gas:Bob Gas stations 52.21 CAD 2022-10-21 Expenses:Gas:Carol Gas stations 52.21 CAD 2022-10-21 Expenses:Gas:Dick Gas stations 52.21 CAD 2022-10-21 Expenses:Gas:Eve Gas stations 52.21 CAD 2022-10-21 Income:Alice Gas stations -130.525 CAD 2022-10-21 Income:Carol Gas stations -130.525 CADdate account payee position ---------- ------------------------- --------------- ------------ 2022-10-18 Expenses:Groceries:* Zehrs 21.79 CAD 2022-10-18 Income:Alice Zehrs -108.95 CAD 2022-10-18 Expenses:Groceries:* Costco 20.928 CAD 2022-10-18 Income:Dick Costco -104.64 CAD 2022-10-19 Expenses:Groceries:* Walmart 12.48 CAD 2022-10-19 Income:Eve Walmart -62.40 CAD 2022-10-19 Expenses:Cottage:* Airbnb 177.183 CAD 2022-10-19 Income:Dick Airbnb -885.915 CAD 2022-10-20 Expenses:ParkPermit:* Provincial Park 4.20 CAD 2022-10-20 Income:Bob Provincial Park -21.00 CAD 2022-10-21 Expenses:Gas:* Gas stations 52.21 CAD 2022-10-21 Income:Alice Gas stations -130.525 CAD 2022-10-21 Income:Carol Gas stations -130.525 CAD
$ bean-query trip.beancount 'SELECT date,account,payee,position WHERE narration ~ "&"'date account payee position ---------- ------------------------ ------ ------------ 2022-10-18 Expenses:Groceries:Alice Zehrs 0.998 CAD 2022-10-18 Expenses:Groceries:Bob Zehrs 0.998 CAD 2022-10-18 Expenses:Groceries:Carol Zehrs 0.998 CAD 2022-10-18 Income:Alice Zehrs -2.994 CAD 2022-10-19 Expenses:Cottage:Alice Airbnb 98.435 CAD 2022-10-19 Expenses:Cottage:Bob Airbnb 98.435 CAD 2022-10-19 Expenses:Cottage:Carol Airbnb 98.435 CAD 2022-10-19 Income:Dick Airbnb -295.305 CADdate account payee position ---------- ------------------------ ------ ------------ 2022-10-18 Expenses:Groceries:* Zehrs 0.998 CAD 2022-10-18 Income:Alice Zehrs -2.994 CAD 2022-10-19 Expenses:Cottage:* Airbnb 98.435 CAD 2022-10-19 Income:Dick Airbnb -295.305 CAD
A negative number means you are being owed!
$ bean-query trip.beancount 'SELECT sum(position) WHERE account ~ ":Alice$"'date account payee position ---------- ------------------------- --------------- ------------ 2022-10-18 Expenses:Groceries:Alice Zehrs 21.79 CAD 2022-10-18 Income:Alice Zehrs -108.95 CAD 2022-10-18 Expenses:Groceries:Alice Zehrs 0.998 CAD 2022-10-18 Income:Alice Zehrs -2.994 CAD 2022-10-18 Expenses:Groceries:Alice Costco 20.928 CAD 2022-10-19 Expenses:Groceries:Alice Walmart 12.48 CAD 2022-10-19 Expenses:Cottage:Alice Airbnb 98.435 CAD 2022-10-19 Expenses:Cottage:Alice Airbnb 177.183 CAD 2022-10-20 Expenses:ParkPermit:Alice Provincial Park 4.20 CAD 2022-10-21 Expenses:Gas:Alice Gas stations 52.21 CAD 2022-10-21 Income:Alice Gas stations -130.525 CADBalance ----------- 145.755 CAD
$ bean-query trip.beancount 'SELECT sum(position) WHERE account ~ ":Bob$"'date account payee position ---------- ----------------------- --------------- ------------ 2022-10-18 Expenses:Groceries:Bob Zehrs 21.79 CAD 2022-10-18 Expenses:Groceries:Bob Zehrs 0.998 CAD 2022-10-18 Expenses:Groceries:Bob Costco 20.928 CAD 2022-10-19 Expenses:Groceries:Bob Walmart 12.48 CAD 2022-10-19 Expenses:Cottage:Bob Airbnb 98.435 CAD 2022-10-19 Expenses:Cottage:Bob Airbnb 177.183 CAD 2022-10-20 Expenses:ParkPermit:Bob Provincial Park 4.20 CAD 2022-10-20 Income:Bob Provincial Park -21.00 CAD 2022-10-21 Expenses:Gas:Bob Gas stations 52.21 CADBalance ----------- 367.224 CAD
$ bean-query trip.beancount 'SELECT sum(position) WHERE account ~ ":Carol$"'date account payee position ---------- ------------------------- --------------- ------------ 2022-10-18 Expenses:Groceries:Carol Zehrs 21.79 CAD 2022-10-18 Expenses:Groceries:Carol Zehrs 0.998 CAD 2022-10-18 Expenses:Groceries:Carol Costco 20.928 CAD 2022-10-19 Expenses:Groceries:Carol Walmart 12.48 CAD 2022-10-19 Expenses:Cottage:Carol Airbnb 98.435 CAD 2022-10-19 Expenses:Cottage:Carol Airbnb 177.183 CAD 2022-10-20 Expenses:ParkPermit:Carol Provincial Park 4.20 CAD 2022-10-21 Expenses:Gas:Carol Gas stations 52.21 CAD 2022-10-21 Income:Carol Gas stations -130.525 CADBalance ----------- 257.699 CAD
$ bean-query trip.beancount 'SELECT sum(position) WHERE account ~ ":Dick$"'date account payee position ---------- ------------------------ --------------- ------------ 2022-10-18 Expenses:Groceries:Dick Zehrs 21.79 CAD 2022-10-18 Expenses:Groceries:Dick Costco 20.928 CAD 2022-10-18 Income:Dick Costco -104.64 CAD 2022-10-19 Expenses:Groceries:Dick Walmart 12.48 CAD 2022-10-19 Income:Dick Airbnb -295.305 CAD 2022-10-19 Expenses:Cottage:Dick Airbnb 177.183 CAD 2022-10-19 Income:Dick Airbnb -885.915 CAD 2022-10-20 Expenses:ParkPermit:Dick Provincial Park 4.20 CAD 2022-10-21 Expenses:Gas:Dick Gas stations 52.21 CADBalance ------------ -997.069 CAD
$ bean-query trip.beancount 'SELECT sum(position) WHERE account ~ ":Eve$"'date account payee position ---------- ----------------------- --------------- ------------ 2022-10-18 Expenses:Groceries:Eve Zehrs 21.79 CAD 2022-10-18 Expenses:Groceries:Eve Costco 20.928 CAD 2022-10-19 Expenses:Groceries:Eve Walmart 12.48 CAD 2022-10-19 Income:Eve Walmart -62.40 CAD 2022-10-19 Expenses:Cottage:Eve Airbnb 177.183 CAD 2022-10-20 Expenses:ParkPermit:Eve Provincial Park 4.20 CAD 2022-10-21 Expenses:Gas:Eve Gas stations 52.21 CADBalance ----------- 226.391 CAD
;; Ledger of shared expenses ;; Participants: Alice, Bob, Carol, Dick, Eve option "operating_currency" "CAD" plugin "beancount.plugins.split_expenses" "Alice Bob Carol Dick Eve" plugin "beancount.plugins.auto_accounts" ;; --------------------------------------------------------- 2022-10-18 * "Zehrs" "Zehrs for all" Expenses:Groceries 108.95 CAD Income:Alice 2022-10-18 * "Zehrs" "Zehrs for Alice & Bob & Carol" Expenses:Groceries:Alice 2.994/3 CAD Expenses:Groceries:Bob 2.994/3 CAD Expenses:Groceries:Carol 2.994/3 CAD Income:Alice ;; --------------------------------------------------------- 2022-10-18 * "Costco" "Costco for all" Expenses:Groceries 104.64 CAD Income:Dick ;; --------------------------------------------------------- 2022-10-19 * "Walmart" "Walmart for all" Expenses:Groceries 62.40 CAD Income:Eve ;; --------------------------------------------------------- 2022-10-19 * "Airbnb" "Cottage 1st night for Alice & Bob & Carol" Expenses:Cottage:Alice (1181.22/4)/3 CAD Expenses:Cottage:Bob (1181.22/4)/3 CAD Expenses:Cottage:Carol (1181.22/4)/3 CAD Income:Dick 2022-10-19 * "Airbnb" "Cottage 3 nights for all" Expenses:Cottage (1181.22/4)*3 CAD Income:Dick ;; --------------------------------------------------------- 2022-10-20 * "Provincial Park" "Park day use for all" Expenses:ParkPermit 21.00 CAD Income:Bob ;; --------------------------------------------------------- 2022-10-21 * "Gas stations" "Gas for all" Expenses:Gas 261.05 CAD Income:Alice -261.05/2 CAD Income:Carol -261.05/2 CAD...