This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Copyright (c) 2015-present, Facebook, Inc. | |
* Copyright (c) 2018 Arctype Corp. | |
* | |
* All rights reserved. | |
* | |
* This source code is licensed under the BSD-style license found in the | |
* LICENSE file in the root directory of the facebook/react source tree. An additional grant | |
* of patent rights can be found in the PATENTS file in the same directory. | |
* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Defines a schema for a multi-tenant, multi-currency, double-entry accounting ledger. | |
-- Trigger design derived from the gist discussion at: | |
-- https://gist.github.com/NYKevin/9433376 | |
-- Data model inspired by: | |
-- https://medium.com/@RobertKhou/double-entry-accounting-in-a-relational-database-2b7838a5d7f8 | |
-- https://developer.squareup.com/blog/books-an-immutable-double-entry-accounting-database-service/ | |
BEGIN; |