forked from plaintextaccounting/plaintextaccounting
-
Notifications
You must be signed in to change notification settings - Fork 0
/
plaintext-accounting-errors.html
107 lines (97 loc) · 6.98 KB
/
plaintext-accounting-errors.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
<!DOCTYPE html>
<html lang="en">
<head>
<!-- Basic Page Needs
–––––––––––––––––––––––––––––––––––––––––––––––––– -->
<meta charset="utf-8">
<title>Don’t Sink Your First Attempts at Plaintext Accounting - plaintextaccounting.org</title>
<meta name="description" content="">
<meta name="author" content="">
<!-- Mobile Specific Metas
–––––––––––––––––––––––––––––––––––––––––––––––––– -->
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- FONT
–––––––––––––––––––––––––––––––––––––––––––––––––– -->
<link href="//fonts.googleapis.com/css?family=Raleway:400,300,600" rel="stylesheet" type="text/css">
<!-- CSS
–––––––––––––––––––––––––––––––––––––––––––––––––– -->
<link rel="stylesheet" href="css/normalize.css">
<link rel="stylesheet" href="css/skeleton.css">
<link rel="stylesheet" href="css/site.css">
<!-- Favicon
–––––––––––––––––––––––––––––––––––––––––––––––––– -->
<link rel="icon" type="image/png" href="images/favicon.png">
</head>
<body>
<!-- Primary Page Layout
–––––––––––––––––––––––––––––––––––––––––––––––––– -->
<div class="container">
<h2 id="dont-sink-your-first-attempts-at-plaintext-accounting">Don’t Sink Your First Attempts at Plaintext Accounting</h2>
<blockquote>
<p>I wrote the article below to help newcomers to plaintext accounting. Simon, if you think this would be useful for any of your websites, you have my permission to post it there. Enjoy! --Robert Nielsen, 2017/04/19</p>
</blockquote>
<p>Plain text accounting programs such as Ledger and Hledger are powerful, helpful tools, but your own user errors can take the wind out of your sails when you would rather be breezing through your accounting. Here, then, are several mistakes—ones that I have personally tested—that you will want to avoid in order to enjoy the benefits of plaintext accounting without unnecessary pain.</p>
<h3 id="preliminary-assumptions">Preliminary assumptions:</h3>
<ul>
<li><p>You have Ledger or Hledger already installed and running on your PC, and you are ready, or have already begun, to start entering your data.</p></li>
<li><p>You understand that there are normally three lines of text for each transaction, and you know basically what’s supposed to go in each line.</p></li>
</ul>
<h3 id="formatting-can-be-critical">Formatting Can Be Critical</h3>
<p>The following two formatting errors will cause your work to come to a screeching halt. Here’s how to avoid them.</p>
<p>First, as you enter transactions, make sure that the second and third (and any additional) lines in a transaction are indented by at least one space. In other words, do this:</p>
<pre class="journal"><code>2017/01/15 Acme
Expenses:Household $20.00 ;roadrunner trap
Liabilities:CreditCard</code></pre>
<p>Not this:</p>
<pre class="journal"><code>2017/01/15 Acme
Expenses:Household $20.00 ;roadrunner trap
Liabilities:CreditCard</code></pre>
<p>The above two transactions look very similar to the human eye, but the second one doesn’t work.</p>
<p>Another formatting issue that’s easy to miss, is that you need at least two spaces between the category ”Expenses:Household,” below) and the amount of the transaction (“$20.00”):</p>
<pre class="journal"><code>2017/01/15 Acme
Expenses:Household $20.00
Liabilities:CreditCard</code></pre>
<p>Contrast this with the wrong way:</p>
<pre class="journal"><code>2017/01/15 Acme
Expenses:Household $20.00
Liabilities:CreditCard</code></pre>
<p>As it’s very hard to see the number of spaces in the critical parts, I have written them out in the two transactions below.</p>
<p>Correct:</p>
<pre class="journal"><code>2017/01/15 Acme
Expenses:Household[space][space]$20.00
Liabilities:CreditCard</code></pre>
<p>Wrong:</p>
<pre class="journal"><code>2017/01/15 Acme
Expenses:Household[space]$20.00
Liabilities:CreditCard</code></pre>
<p>Again, it’s easy for us humans to miss the difference between one space and two, but your plaintext accounting program will notice.</p>
<h3 id="use-currency-symbols-consistently">Use Currency Symbols Consistently</h3>
<p>Here’s another error that’s easy to make and easy to overlook – omitting a currency symbol. For example:</p>
<pre class="journal"><code>2017/01/15 Acme
Expenses:Household 20.00
Liabilities:CreditCard</code></pre>
<p>If you have been working with US dollars, it’s very easy to think that the above 20.00 refers to $20.00, but Ledger and Hledger will process this amount as something other than US dollars.</p>
<h3 id="using-a-comma-when-you-need-a-period">Using a Comma When You Need a Period</h3>
<p>Another mistake to avoid is inadvertently typing a comma where a decimal in required. Let’s say, for example, that you are recording the purchase of a yacht for slightly more than $1.2 million. Here is the error:</p>
<pre class="journal"><code>2017/01/16 Mega Yacht Company
Expenses:Leisure $1,245,449,72
Assets:Bank:Checking</code></pre>
<p>The correct way to write this is:</p>
<pre class="journal"><code>2017/01/16 Mega Yacht Company
Expenses:Leisure $1,245,449.72
Assets:Bank:Checking</code></pre>
<p>If you are using Emacs, erroneously using a comma instead of a decimal point as shown above can manifest itself as a confusing error message about no transactions that need to be cleared.</p>
<p>Finally, the above examples assume you are using a numbering system that separates thousands with commas and integers from fractions with periods. There are systems that separate thousands with periods and that use commas to separate integers and fractions. From my reading of the documentation, both Ledger and Hledger can work with either system, but the point remains not to use a comma when you mean to use a period and vice versa.</p>
<h3 id="summary">Summary</h3>
<ul>
<li><p>Indent the second and following lines of each transaction. The first line of the transaction needs to be flush left.</p></li>
<li><p>Use two spaces after the transaction category and before the currency symbol (assuming that you are working with currency).</p></li>
<li><p>Use the currency symbol before every amount that’s currency.</p></li>
<li><p>Don’t use a comma when you need to write a decimal point.</p></li>
</ul>
<p>So, avoid the above mistakes and enjoy some clear sailing with plaintext accounting.</p>
</div>
<!-- End Document
–––––––––––––––––––––––––––––––––––––––––––––––––– -->
</body>
</html>