jl/schema/tables/gl.sql

16 lines
668 B
MySQL
Raw Normal View History

2018-09-12 14:48:59 -04:00
--------------------------relational ledger------------------------------------------
CREATE TABLE evt.gl (
id INT GENERATED ALWAYS AS IDENTITY PRIMARY KEY
2018-09-17 23:42:01 -04:00
,bprid INT REFERENCES evt.bpr (id)
2018-09-18 00:11:45 -04:00
,account text REFERENCES evt.acct (acct)
2018-09-12 14:48:59 -04:00
,amount numeric (12,2)
2018-09-17 23:42:01 -04:00
,glline INT
,bprkeys JSONB
2018-09-12 14:48:59 -04:00
);
2018-09-17 23:42:01 -04:00
COMMENT ON COLUMN evt.gl.id IS 'gl id';
COMMENT ON COLUMN evt.gl.bprid IS 'id of initial basic pecuniary record';
2018-09-12 14:48:59 -04:00
COMMENT ON COLUMN evt.gl.acct IS 'account code';
COMMENT ON COLUMN evt.gl.amount IS 'amount';
2018-09-17 23:42:01 -04:00
COMMENT ON COLUMN evt.gl.glline IS 'gl line number';
COMMENT ON COLUMN evt.gl.bprkeys IS 'extract from initial basic pecuniary record';