【发布时间】:2017-03-24 11:29:44
【问题描述】:
我正在研究一种会计解决方案,其中 db 有以下相关列:
1. Account (The chart-of-account column)
2. Journal (This is one row for each journal entry)
3. Journal Line Item (Now, one journal entry can have more than 2
entries, hence this 3rd table, with a FK to 2nd table). This table has
an FK to Table 1 as well
现在,假设我们需要在 1 月份生成跟踪余额(假设会计年度是从 4 月 1 日到 3 月 31 日)。截至目前,我必须对所有日记帐分录进行完整总结,以便做出报告。 这适用于所有其他报告。有更好的数据库设计/方法吗?
P.S.:一种方法是保持表 1 中日期的帐户余额。但是,假设用户需要上个月/季度的试算表?这会导致溶液再次出现在汤中。
注意:我们使用的是 Django、Postgresql。
【问题讨论】:
-
这个问题非常适合会计网站(目前在51区的提案:area51.stackexchange.com/proposals/113560/…)
标签: django postgresql database-design accounting