[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] simple expense tracking with org
From: |
Eike |
Subject: |
Re: [O] simple expense tracking with org |
Date: |
Sat, 20 Sep 2014 15:35:41 +0200 |
Sure. An "expense item" is a headline with a property drawer that has a
property where the key is some currency code (other headlines are
ignored). Then tags can be applied to this headline. A category is
either specified via CATEGORY property or the parent headline is used
(if present).
The org files may look like this
* some headline that is a category by default
** expense item 1 :atag:
:PROPERTIES:
:CHF: 25.00
:date: [2014-09-20]
:END:
** expense item 2 :anothertag:
:PROPERTIES:
:CHF: 21.00
:date: [2014-09-20]
:CATEGORY:
:END:
The "expense view" gives a summary of these items and the items itself
as a org table (there also is a screenshot
https://github.com/eikek/org-expenses/blob/master/screenshot.png):
#+TITLE: Expenses [2014-08-01 Fr] - [2014-08-31 So]
#+STARTUP: showeverything
Search: ~(:date "2014-08")~
Showing *7* items
* Overview
** Summary
| Curr. | sum | max | min | count | avg |
|-------+--------+--------+-------+-------+-------|
| CHF | 532.98 | 349.99 | 10.00 | 6 | 88.83 |
| EUR | 15.99 | 15.99 | 15.99 | 1 | 15.99 |
** Categories
| | sum | max | min | count | avg |
|---------------+--------+--------+-------+-------+--------|
| Bücher CHF | 49.99 | 39.99 | 10.00 | 2 | 25.00 |
| Bücher EUR | 15.99 | 15.99 | 15.99 | 1 | 15.99 |
| Sonstiges CHF | 426.49 | 349.99 | 20.00 | 3 | 142.16 |
| Work CHF | 56.50 | 56.50 | 56.50 | 1 | 56.50 |
** Monthly
| | sum | max | min | count | avg |
|-------------+--------+--------+-------+-------+-------|
| 2014/08 CHF | 532.98 | 349.99 | 10.00 | 6 | 88.83 |
| 2014/08 EUR | 15.99 | 15.99 | 15.99 | 1 | 15.99 |
* Items
| :item | :category | :date | :CHF | :EUR |
|-----------+-----------+-----------------+--------+-------|
| Buch1 | Bücher | [2014-08-31 So] | | 15.99 |
| Cellphone | Sonstiges | [2014-08-30 Sa] | 349.99 | |
| Pizza | Sonstiges | [2014-08-29 Fr] | 20.00 | |
| Buch2 | Bücher | [2014-08-26 Di] | 10.00 | |
| Cablecom | Sonstiges | [2014-08-25 Mo] | 56.50 | |
| Cablecom | Work | [2014-08-25 Mo] | 56.50 | |
| Buch2 | Bücher | [2014-08-01 Fr] | 39.99 | |
It's just counting and summing the items, nothing more. It's not doing
accounting or anythingmore complicated, if you had this in mind.
Regard,
Eike
Tory S. Anderson writes:
> Could you give a few snippets of examples -- what the org files with tags
> look like, what the result looks like? I'm interested because I also use Org
> to do my budgeting and finances.
>
> Eike <address@hidden> writes:
>
>> Hello there,
>>
>> I thought to share a little elisp thingy that I wrote to track my
>> expenses with org. I use the org's capture mechanism to add expense
>> items to some files and the following code only searches through all
>> these files and creates summaries of all found expenses. It is possible
>> to search by date, tags etc.
>>
>> You can have a look here: https://github.com/eikek/org-expenses
>>
>>
>> Regards,
>> Eike
>>
>> --
>> gpg: AD7AC35E
>> finger print: 137F BB0B 1639 D25F DC5D E59C B412 C5F5 AD7A C35E
--
gpg: AD7AC35E
finger print: 137F BB0B 1639 D25F DC5D E59C B412 C5F5 AD7A C35E