Regular expressions in GnuCash

AC gnucash at acarver.net
Sun Sep 25 16:47:10 EDT 2016


Numeric fields do not have to be in any particular order.  If they did
nearly every database on the planet would be broken right now.  Real
bank databases treat checks as numeric values (assuming the bank issues
numerically serialized checks).  You can then perform any standard
numeric lookups on checks just like with dates (printed dates are
strings but stored as numbers, too, in most databases so that you can do
math on dates).

If banks didn't treat check numbers as numbers it would be harder to
detect an out-of-order check.  Math with check numbers:  sort by date
then look at locations where the difference between adjacent numeric
fields is negative, the results are the out-of-order checks.

More math with check numbers:
Checkbooks have a fixed number of checks inside with a known start and
end number.  If the client has written a check that is N away from the
largest known check number available to them (i.e. the last check from
the most recent order of checkbooks), send the client a reminder to
order more checks.

I did a search anyway to find out if there were any checks that used
anything other than numeric values.  I have not found any and the main
reason is that the standardized MICR line at the bottom of any check
contains the check number.  The MICR font does not support alphabetic
characters therefore checks can not be numbered with anything other than
digits.

On 2016-09-25 12:11, Adrien Monteleone wrote:
> Changing ‘Num’ to a numeric type is not the way to go. You see, while
> it appears that ‘check numbers’ are numeric, they are not. You do not
> perform math with them. (you can, sometimes, but not always) They are
> labels identifying a particular check. They just are in a sequence
> using numerals. Technically, they don’t have to be in sequence and
> you can even jump around in sequences when you order checks with an
> account as long as that range hasn’t been used prior. As well, it is
> certainly possible to write a check out of sequence entirely, say,
> from a forgotten but unused book of checks completely out of sequence
> from others written during the same period.
> 


More information about the gnucash-user mailing list