From 18bc4f0a2563a98273dae60b50235346816ca2cf Mon Sep 17 00:00:00 2001 From: einhverfr Date: Wed, 13 Jun 2007 18:30:01 +0000 Subject: Updating database schema diagrams and documentation git-svn-id: https://ledger-smb.svn.sourceforge.net/svnroot/ledger-smb/trunk@1274 4979c152-3d1c-0410-bac9-87ea11338e46 --- doc/database/ledgersmb.dia | 10078 +++++++++++++++++++++++----------- doc/database/ledgersmb.dot | 114 +- doc/database/ledgersmb.html | 4827 ++++++++++++----- doc/database/ledgersmb.neato | 114 +- doc/database/ledgersmb.xml | 4912 ++++++++++++----- doc/database/ledgersmb.zigzag.dia | 10518 +++++++++++++++++++++++++----------- 6 files changed, 21541 insertions(+), 9022 deletions(-) (limited to 'doc') diff --git a/doc/database/ledgersmb.dia b/doc/database/ledgersmb.dia index 6972d12b..0b8b9e86 100644 --- a/doc/database/ledgersmb.dia +++ b/doc/database/ledgersmb.dia @@ -457,11 +457,11 @@ # id# - #integer# + #serial# - #nextval('id'::regclass)# + @@ -523,7 +523,7 @@ - # vendor_id# + # entity_id# #integer# @@ -776,7 +776,7 @@ - # employee_id# + # person_id# #integer# @@ -1113,11 +1113,11 @@ # id# - #integer# + #serial# - #nextval('id'::regclass)# + @@ -1179,7 +1179,7 @@ - # customer_id# + # entity_id# #integer# @@ -1478,7 +1478,7 @@ - # employee_id# + # person_id# #integer# @@ -2123,7 +2123,7 @@ - # employee_id# + # person_id# #integer# @@ -2276,11 +2276,11 @@ # id# - #integer# + #serial# - #nextval('id'::regclass)# + @@ -2449,11 +2449,11 @@ # id# - #integer# + #serial# - #nextval('id'::regclass)# + @@ -2658,7 +2658,7 @@ - #custom_field_catalog# + #company# @@ -2734,7 +2734,7 @@ - # field_id# + # id# #serial# @@ -2757,7 +2757,7 @@ - # table_id# + # entity_id# #integer# @@ -2780,7 +2780,76 @@ - # field_name# + # legal_name# + + + #text# + + + + + + + + + + + + + + + + + + + + # entity_class_id# + + + #integer# + + + + + + + + + + + + + + + + + + + + # primary_location_id# + + + #integer# + + + + + + + + + + + + + + + + + + + + # tax_id# #text# @@ -2804,9 +2873,42 @@ - + + + + + + + #company_legal_name_check# + + + + + + + + + + + + + + #CHECK ((legal_name ~ '[[:alnum ... ext))# + + + ## + + + + + + + + + + + - @@ -2831,11 +2933,11 @@ - #custom_table_catalog# + #company_to_contact# - ## + # To keep track of the relationship ... pany # @@ -2907,10 +3009,10 @@ - # table_id# + # company_id# - #serial# + #integer# @@ -2930,10 +3032,10 @@ - # extends# + # contact_class_id# - #text# + #integer# @@ -2953,7 +3055,7 @@ - # table_name# + # contact# #text# @@ -2977,9 +3079,42 @@ - + + + + + + + #company_to_contact_contact_check# + + + + + + + + + + + + + + #CHECK ((contact ~ '[[:alnum:]_ ... ext))# + + + ## + + + + + + + + + + + - @@ -3004,7 +3139,7 @@ - #customer# + #company_to_entity# @@ -3080,57 +3215,11 @@ - # id# + # company_id# #integer# - - - #nextval('id'::regclass)# - - - - - - - - - - - - - - - - # name# - - - #character varying(64)# - - - - - - - - - - - - - - - - - - - - # address1# - - - #character varying(32)# - @@ -3149,10 +3238,10 @@ - # address2# + # entity_id# - #character varying(32)# + #integer# @@ -3172,10 +3261,10 @@ - # city# + # related_how# - #character varying(32)# + #text# @@ -3195,14 +3284,14 @@ - # state# + # created# - #character varying(32)# + #date# - + #('now'::text)::date# @@ -3216,40 +3305,16 @@ - - - # zipcode# - - - #character varying(10)# - - - - + - - - - - - - - - - - + + + + - + - # country# - - - #character varying(32)# - - - - - + #company_to_entity_check# @@ -3260,60 +3325,129 @@ - - - - - # contact# - - - #character varying(64)# - - - - - - - - - - - - - - + + + + #CHECK ((entity_id <> company_id))# + + + ## + + + + + + + + - - - # phone# - - - #character varying(20)# - - + - + + + + + - - - - - - - - - - - + + + + + + + + + + + + + + + + + + #company_to_location# + + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - # fax# + # location_id# - #character varying(20)# + #integer# @@ -3333,10 +3467,10 @@ - # email# + # company_id# - #text# + #integer# @@ -3354,35 +3488,116 @@ - - - # notes# - - - #text# - - + - + + + + - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + #contact_class# + + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - # discount# + # id# - #numeric# + #serial# @@ -3402,14 +3617,14 @@ - # taxincluded# + # class# - #boolean# + #text# - #false# + @@ -3423,17 +3638,16 @@ - - - # creditlimit# - - - #numeric# - - + - + + + + + + + #contact_class_class_check# @@ -3444,37 +3658,129 @@ + + + + #CHECK (("class" ~ '[[:alnum:]_ ... ext))# + + + ## + + + + + + + + + - - - # terms# - - - #smallint# - - + - + + + + + - - - - - - - - - - - + + + + + + + + + + + + + + + + + + #country# + + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - # customernumber# + # id# - #character varying(32)# + #serial# @@ -3494,7 +3800,7 @@ - # cc# + # name# #text# @@ -3517,7 +3823,7 @@ - # bcc# + # short_name# #text# @@ -3540,10 +3846,10 @@ - # business_id# + # itu# - #integer# + #text# @@ -3561,17 +3867,16 @@ - - - # taxnumber# - - - #character varying(32)# - - + - + + + + + + + #country_name_check# @@ -3582,19 +3887,27 @@ + + + + #CHECK ((name ~ '[[:alnum:]_]'::text))# + + + ## + + + + + + + + + - + - # sic_code# - - - #character varying(6)# - - - - - + #country_short_name_check# @@ -3605,14 +3918,129 @@ + + + + #CHECK ((short_name ~ '[[:alnum ... ext))# + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + #custom_field_catalog# + + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - # iban# + # field_id# - #character varying(34)# + #serial# @@ -3632,10 +4060,10 @@ - # bic# + # table_id# - #character varying(11)# + #integer# @@ -3655,125 +4083,10 @@ - # employee_id# + # field_name# - #integer# - - - - - - - - - - - - - - - - - - - - # language_code# - - - #character varying(6)# - - - - - - - - - - - - - - - - - - - - # pricegroup_id# - - - #integer# - - - - - - - - - - - - - - - - - - - - # curr# - - - #character(3)# - - - - - - - - - - - - - - - - - - - - # startdate# - - - #date# - - - - - - - - - - - - - - - - - - - - # enddate# - - - #date# + #text# @@ -3804,7 +4117,7 @@ - + @@ -3821,7 +4134,7 @@ - #customertax# + #custom_table_catalog# @@ -3897,10 +4210,10 @@ - # customer_id# + # table_id# - #integer# + #serial# @@ -3920,10 +4233,33 @@ - # chart_id# + # extends# - #integer# + #text# + + + + + + + + + + + + + + + + + + + + # table_name# + + + #text# @@ -3954,7 +4290,7 @@ - + @@ -3971,11 +4307,11 @@ - #defaults# + #customer# - ## + # This is now a metadata table that ... ment # @@ -4047,10 +4383,10 @@ - # setting_key# + # id# - #text# + #serial# @@ -4070,10 +4406,10 @@ - # value# + # entity_id# - #text# + #integer# @@ -4091,120 +4427,62 @@ - + + + # discount# + + + #numeric# + + - - - - + - - - - - + + + + + + + + + + + - - - - - - - - - - - - - - - - - - #department# - + + + # taxincluded# + + + #boolean# + + - - ## - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + #false# + + + + + + + + + + + + - # id# + # creditlimit# - #integer# + #numeric# - #nextval('id'::regclass)# + @@ -4220,10 +4498,10 @@ - # description# + # terms# - #text# + #smallint# @@ -4243,14 +4521,14 @@ - # role# + # customernumber# - #character(1)# + #character varying(32)# - #'P'::bpchar# + @@ -4264,113 +4542,55 @@ - + + + # cc# + + + #text# + + - - - - + - - - - - + + + + + + + + + + + - - - - - - - - - - - - - - - - - - #dpt_trans# - + + + # bcc# + + + #text# + + - - ## - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + - # trans_id# + # business_id# #integer# @@ -4393,10 +4613,10 @@ - # department_id# + # sic_code# - #integer# + #character varying(6)# @@ -4414,120 +4634,39 @@ - - - - - - + + + # iban# + + + #character varying(34)# + + - - - - - + - - - - - - - - - - - - - - - - - - #employee# - - - - ## - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + - # id# + # bic# - #integer# + #character varying(11)# - #nextval('id'::regclass)# + @@ -4543,10 +4682,10 @@ - # login# + # language_code# - #text# + #character varying(6)# @@ -4566,10 +4705,10 @@ - # name# + # pricegroup_id# - #character varying(64)# + #integer# @@ -4589,10 +4728,10 @@ - # address1# + # curr# - #character varying(32)# + #character(3)# @@ -4612,14 +4751,14 @@ - # address2# + # startdate# - #character varying(32)# + #date# - + #('now'::text)::date# @@ -4635,10 +4774,10 @@ - # city# + # enddate# - #character varying(32)# + #date# @@ -4658,10 +4797,10 @@ - # state# + # invoice_notes# - #character varying(32)# + #text# @@ -4679,58 +4818,116 @@ - - - # zipcode# - - - #character varying(10)# - - - - + - - - - - - - - - - - + + + + - - - # country# - - - #character varying(32)# - - + + + + + - + + + + + + + + + + + + + + + + + + #customertax# + - - - - - - - - - - - + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - # workphone# + # customer_id# - #character varying(20)# + #integer# @@ -4750,10 +4947,10 @@ - # homephone# + # chart_id# - #character varying(20)# + #integer# @@ -4771,35 +4968,116 @@ - - - # startdate# - - - #date# - - + - #('now'::text)::date# + + + + - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + #defaults# + + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - # enddate# + # setting_key# - #date# + #text# @@ -4819,7 +5097,7 @@ - # notes# + # value# #text# @@ -4840,39 +5118,120 @@ - - - # role# - - - #character varying(20)# - - + - + + + + - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + #department# + + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - # sales# + # id# - #boolean# + #serial# - #false# + @@ -4888,7 +5247,7 @@ - # email# + # description# #text# @@ -4911,14 +5270,14 @@ - # ssn# + # role# - #character varying(20)# + #character(1)# - + #'P'::bpchar# @@ -4932,122 +5291,7 @@ - - - # iban# - - - #character varying(34)# - - - - - - - - - - - - - - - - - - - - # bic# - - - #character varying(11)# - - - - - - - - - - - - - - - - - - - - # managerid# - - - #integer# - - - - - - - - - - - - - - - - - - - - # employeenumber# - - - #character varying(32)# - - - - - - - - - - - - - - - - - - - - # dob# - - - #date# - - - - - - - - - - - - - - - - - - + @@ -5060,7 +5304,7 @@ - + @@ -5077,7 +5321,7 @@ - #exchangerate# + #dpt_trans# @@ -5153,56 +5397,10 @@ - # curr# - - - #character(3)# - - - - - - - - - - - - - - - - - - - - # transdate# - - - #date# - - - - - - - - - - - - - - - - - - - - # buy# + # trans_id# - #numeric# + #integer# @@ -5222,10 +5420,10 @@ - # sell# + # department_id# - #numeric# + #integer# @@ -5256,7 +5454,7 @@ - + @@ -5273,11 +5471,11 @@ - #gifi# + #employee# - ## + # Is a metadata table specific to employees # @@ -5349,10 +5547,10 @@ - # accno# + # id# - #text# + #serial# @@ -5372,7 +5570,30 @@ - # description# + # entity_id# + + + #integer# + + + + + + + + + + + + + + + + + + + + # login# #text# @@ -5393,120 +5614,62 @@ - + + + # startdate# + + + #date# + + - - - - + #('now'::text)::date# - - - - - + + + + + + + + + + + - - - - - - - - - - - - - - - - - - #gl# - + + + # enddate# + + + #date# + + - - ## - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + - # id# + # notes# - #integer# + #text# - #nextval('id'::regclass)# + @@ -5522,10 +5685,10 @@ - # reference# + # role# - #text# + #character varying(20)# @@ -5545,10 +5708,33 @@ - # description# + # sales# - #text# + #boolean# + + + + #false# + + + + + + + + + + + + + + + + # ssn# + + + #character varying(20)# @@ -5568,14 +5754,37 @@ - # transdate# + # iban# - #date# + #character varying(34)# - #('now'::text)::date# + + + + + + + + + + + + + + + + + # bic# + + + #character varying(11)# + + + + @@ -5591,7 +5800,7 @@ - # employee_id# + # managerid# #integer# @@ -5614,10 +5823,10 @@ - # notes# + # employeenumber# - #text# + #character varying(32)# @@ -5637,10 +5846,10 @@ - # department_id# + # dob# - #integer# + #date# @@ -5671,7 +5880,7 @@ - + @@ -5688,11 +5897,11 @@ - #inventory# + #entity# - ## + # The primary entity table to map to ... acts # @@ -5764,10 +5973,10 @@ - # warehouse_id# + # id# - #integer# + #serial# @@ -5787,10 +5996,10 @@ - # parts_id# + # name# - #integer# + #text# @@ -5810,7 +6019,7 @@ - # trans_id# + # entity_class# #integer# @@ -5831,40 +6040,16 @@ - - - # orderitems_id# - - - #integer# - - - - + - - - - - - - - - - - + + + + - + - # qty# - - - #numeric# - - - - - + #entity_name_check# @@ -5875,91 +6060,33 @@ - - - - - # shippingdate# - - - #date# - - - - - - - - - - - - - - + + + + #CHECK ((name ~ '[[:alnum:]_]'::text))# + + + ## + + + + + + + + - - - # employee_id# - - - #integer# - - - - + - - - - - - - - - - - + + + + + - - - # entry_id# - - - #serial# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + @@ -5976,11 +6103,11 @@ - #invoice# + #entity_class# - ## + # Defines the class type such as ven ... oyee # @@ -6055,53 +6182,7 @@ # id# - #integer# - - - - #nextval('invoicei ... lass)# - - - - - - - - - - - - - - - - # trans_id# - - - #integer# - - - - - - - - - - - - - - - - - - - - # parts_id# - - - #integer# + #serial# @@ -6121,7 +6202,7 @@ - # description# + # class# #text# @@ -6144,14 +6225,14 @@ - # qty# + # active# - #integer# + #boolean# - + #true# @@ -6165,17 +6246,16 @@ - - - # allocated# - - - #integer# - - + - + + + + + + + #entity_class_class_check# @@ -6186,37 +6266,129 @@ + + + + #CHECK (("class" ~ '[[:alnum:]_ ... ext))# + + + ## + + + + + + + + + - - - # sellprice# - - - #numeric# - - + - + + + + + - - - - - - - - - - - + + + + + + + + + + + + + + + + + + #entity_class_to_entity# + + + + # Relation builder for classes to entity # + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - # fxsellprice# + # entity_class_id# - #numeric# + #integer# @@ -6236,10 +6408,10 @@ - # discount# + # entity_id# - #real# + #integer# @@ -6257,55 +6429,113 @@ - - - # assemblyitem# - - - #boolean# - - + - #false# + + + + - - - - - - - - - - - + + + + + - - - # unit# - - - #character varying(5)# - - - - + + + + + + + + + + + + + + + + + + #entity_other_name# + - - - - - - - - - - - + + # Similar to company_other_name, a p ... son. # + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - # project_id# + # entity_id# #integer# @@ -6328,30 +6558,7 @@ - # deliverydate# - - - #date# - - - - - - - - - - - - - - - - - - - - # serialnumber# + # other_name# #text# @@ -6372,17 +6579,16 @@ - - - # notes# - - - #text# - - + - + + + + + + + #entity_other_name_other_name_check# @@ -6393,22 +6599,33 @@ + + + + #CHECK ((other_name ~ '[[:alnum ... ext))# + + + ## + + + + + + + + + - - - - - - + @@ -6425,7 +6642,7 @@ - #jcitems# + #exchangerate# @@ -6501,56 +6718,10 @@ - # id# - - - #integer# - - - - #nextval('jcitemsi ... lass)# - - - - - - - - - - - - - - - - # project_id# - - - #integer# - - - - - - - - - - - - - - - - - - - - # parts_id# + # curr# - #integer# + #character(3)# @@ -6570,10 +6741,10 @@ - # description# + # transdate# - #text# + #date# @@ -6593,7 +6764,7 @@ - # qty# + # buy# #numeric# @@ -6616,7 +6787,7 @@ - # allocated# + # sell# #numeric# @@ -6637,181 +6808,20 @@ - - - # sellprice# - - - #numeric# - - - - - - - - - - - - - - - - + - - - # fxsellprice# - - - #numeric# - - + + + + - + + + + + - - - - - - - - - - - - - - - # serialnumber# - - - #text# - - - - - - - - - - - - - - - - - - - - # checkedin# - - - #timestamp with time zone# - - - - - - - - - - - - - - - - - - - - # checkedout# - - - #timestamp with time zone# - - - - - - - - - - - - - - - - - - - - # employee_id# - - - #integer# - - - - - - - - - - - - - - - - - - - - # notes# - - - #text# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + @@ -6828,7 +6838,7 @@ - #language# + #gifi# @@ -6904,10 +6914,10 @@ - # code# + # accno# - #character varying(6)# + #text# @@ -6961,7 +6971,7 @@ - + @@ -6978,7 +6988,7 @@ - #makemodel# + #gl# @@ -7054,10 +7064,10 @@ - # parts_id# + # id# - #integer# + #serial# @@ -7077,7 +7087,7 @@ - # make# + # reference# #text# @@ -7100,7 +7110,76 @@ - # model# + # description# + + + #text# + + + + + + + + + + + + + + + + + + + + # transdate# + + + #date# + + + + #('now'::text)::date# + + + + + + + + + + + + + + + + # person_id# + + + #integer# + + + + + + + + + + + + + + + + + + + + # notes# #text# @@ -7121,6 +7200,29 @@ + + + # department_id# + + + #integer# + + + + + + + + + + + + + + + + + @@ -7134,7 +7236,7 @@ - + @@ -7151,7 +7253,7 @@ - #oe# + #inventory# @@ -7227,14 +7329,14 @@ - # id# + # warehouse_id# #integer# - #nextval('id'::regclass)# + @@ -7250,10 +7352,10 @@ - # ordnumber# + # parts_id# - #text# + #integer# @@ -7273,14 +7375,14 @@ - # transdate# + # trans_id# - #date# + #integer# - #('now'::text)::date# + @@ -7296,7 +7398,7 @@ - # vendor_id# + # orderitems_id# #integer# @@ -7319,10 +7421,10 @@ - # customer_id# + # qty# - #integer# + #numeric# @@ -7342,10 +7444,10 @@ - # amount# + # shippingdate# - #numeric# + #date# @@ -7365,10 +7467,10 @@ - # netamount# + # person_id# - #numeric# + #integer# @@ -7388,10 +7490,10 @@ - # reqdate# + # entry_id# - #date# + #serial# @@ -7409,12 +7511,116 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + #invoice# + + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - # taxincluded# + # id# - #boolean# + #serial# @@ -7434,10 +7640,10 @@ - # shippingpoint# + # trans_id# - #text# + #integer# @@ -7457,10 +7663,10 @@ - # notes# + # parts_id# - #text# + #integer# @@ -7480,10 +7686,10 @@ - # curr# + # description# - #character(3)# + #text# @@ -7503,7 +7709,7 @@ - # employee_id# + # qty# #integer# @@ -7526,14 +7732,14 @@ - # closed# + # allocated# - #boolean# + #integer# - #false# + @@ -7549,14 +7755,14 @@ - # quotation# + # sellprice# - #boolean# + #numeric# - #false# + @@ -7572,10 +7778,10 @@ - # quonumber# + # fxsellprice# - #text# + #numeric# @@ -7595,10 +7801,10 @@ - # intnotes# + # discount# - #text# + #real# @@ -7618,10 +7824,33 @@ - # department_id# + # assemblyitem# - #integer# + #boolean# + + + + #false# + + + + + + + + + + + + + + + + # unit# + + + #character varying(5)# @@ -7641,10 +7870,10 @@ - # shipvia# + # project_id# - #text# + #integer# @@ -7664,10 +7893,10 @@ - # language_code# + # deliverydate# - #character varying(6)# + #date# @@ -7687,7 +7916,7 @@ - # ponumber# + # serialnumber# #text# @@ -7710,10 +7939,10 @@ - # terms# + # notes# - #smallint# + #text# @@ -7744,7 +7973,7 @@ - + @@ -7761,7 +7990,7 @@ - #orderitems# + #jcitems# @@ -7840,11 +8069,11 @@ # id# - #integer# + #serial# - #nextval('orderite ... lass)# + @@ -7860,7 +8089,7 @@ - # trans_id# + # project_id# #integer# @@ -7952,7 +8181,7 @@ - # sellprice# + # allocated# #numeric# @@ -7975,7 +8204,7 @@ - # discount# + # sellprice# #numeric# @@ -7998,10 +8227,10 @@ - # unit# + # fxsellprice# - #character varying(5)# + #numeric# @@ -8021,10 +8250,10 @@ - # project_id# + # serialnumber# - #integer# + #text# @@ -8044,10 +8273,10 @@ - # reqdate# + # checkedin# - #date# + #timestamp with time zone# @@ -8067,10 +8296,10 @@ - # ship# + # checkedout# - #numeric# + #timestamp with time zone# @@ -8090,10 +8319,10 @@ - # serialnumber# + # person_id# - #text# + #integer# @@ -8147,7 +8376,7 @@ - + @@ -8164,7 +8393,7 @@ - #parts# + #language# @@ -8240,14 +8469,14 @@ - # id# + # code# - #integer# + #character varying(6)# - #nextval('id'::regclass)# + @@ -8263,7 +8492,7 @@ - # partnumber# + # description# #text# @@ -8284,58 +8513,116 @@ - - - # description# - - - #text# - - + - - - - - - - - - - - - - + + + + - - - # unit# - - - #character varying(5)# - - + + + + + - + + + + + + + + + + + + + + + + + + #location# + - - - - - - - - - - - + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - # listprice# + # id# - #numeric# + #serial# @@ -8355,10 +8642,10 @@ - # sellprice# + # line_one# - #numeric# + #text# @@ -8378,10 +8665,10 @@ - # lastcost# + # line_two# - #numeric# + #text# @@ -8401,14 +8688,14 @@ - # priceupdate# + # line_three# - #date# + #text# - #('now'::text)::date# + @@ -8424,10 +8711,10 @@ - # weight# + # city_province# - #numeric# + #text# @@ -8447,10 +8734,10 @@ - # onhand# + # country_id# - #numeric# + #integer# @@ -8470,7 +8757,7 @@ - # notes# + # mail_code# #text# @@ -8491,40 +8778,16 @@ - - - # makemodel# - - - #boolean# - - - - #false# + - - - - - - - - - - - + + + + - + - # assembly# - - - #boolean# - - - - #false# - + #location_city_province_check# @@ -8535,42 +8798,27 @@ - - - - - # alternate# - - - #boolean# - - - - #false# - - - - - - - - - - + + + + #CHECK ((city_province ~ '[[:al ... ext))# + + + ## + + + + + + + + - + - # rop# - - - #real# - - - - - + #location_line_one_check# @@ -8581,19 +8829,27 @@ + + + + #CHECK ((line_one ~ '[[:alnum:] ... ext))# + + + ## + + + + + + + + + - + - # inventory_accno_id# - - - #integer# - - - - - + #location_mail_code_check# @@ -8604,34 +8860,126 @@ + + + + #CHECK ((mail_code ~ '[[:alnum: ... ext))# + + + ## + + + + + + + + + - - - # income_accno_id# - - - #integer# - - + - + + + + + - - - - - - - - - - - + + + + + + + + + + + + + + + + + + #makemodel# + + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - # expense_accno_id# + # parts_id# #integer# @@ -8654,7 +9002,7 @@ - # bin# + # make# #text# @@ -8677,14 +9025,14 @@ - # obsolete# + # model# - #boolean# + #text# - #false# + @@ -8698,16 +9046,120 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + #oe# + + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - # bom# + # id# - #boolean# + #serial# - #false# + @@ -8723,7 +9175,7 @@ - # image# + # ordnumber# #text# @@ -8746,14 +9198,14 @@ - # drawing# + # transdate# - #text# + #date# - + #('now'::text)::date# @@ -8769,10 +9221,10 @@ - # microfiche# + # entity_id# - #text# + #integer# @@ -8792,10 +9244,10 @@ - # partsgroup_id# + # amount# - #integer# + #numeric# @@ -8815,10 +9267,10 @@ - # project_id# + # netamount# - #integer# + #numeric# @@ -8838,10 +9290,10 @@ - # avgcost# + # reqdate# - #numeric# + #date# @@ -8859,116 +9311,58 @@ - - - - - - + + + # taxincluded# + + + #boolean# + + - - - - - + - - - - - - - - - - - - - - - - - - #partscustomer# - + + + + + + + + + + + - - ## - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + # shippingpoint# + + + #text# + + + + + + + + + + + + + + + + - # parts_id# + # notes# - #integer# + #text# @@ -8988,10 +9382,10 @@ - # customer_id# + # curr# - #integer# + #character(3)# @@ -9011,7 +9405,7 @@ - # pricegroup_id# + # person_id# #integer# @@ -9034,10 +9428,56 @@ - # pricebreak# + # closed# - #numeric# + #boolean# + + + + #false# + + + + + + + + + + + + + + + + # quotation# + + + #boolean# + + + + #false# + + + + + + + + + + + + + + + + # quonumber# + + + #text# @@ -9057,10 +9497,10 @@ - # sellprice# + # intnotes# - #numeric# + #text# @@ -9080,10 +9520,10 @@ - # validfrom# + # department_id# - #date# + #integer# @@ -9103,10 +9543,10 @@ - # validto# + # shipvia# - #date# + #text# @@ -9126,10 +9566,10 @@ - # curr# + # language_code# - #character(3)# + #character varying(6)# @@ -9149,10 +9589,56 @@ - # entry_id# + # ponumber# - #serial# + #text# + + + + + + + + + + + + + + + + + + + + # terms# + + + #smallint# + + + + + + + + + + + + + + + + + + + + # oe_class_id# + + + #integer# @@ -9183,7 +9669,7 @@ - + @@ -9200,11 +9686,11 @@ - #partsgroup# + #oe_class# - ## + # This could probably be done better ... tion # @@ -9279,11 +9765,11 @@ # id# - #integer# + #smallint# - #nextval('id'::regclass)# + @@ -9299,7 +9785,7 @@ - # partsgroup# + # oe_class# #text# @@ -9323,17 +9809,50 @@ - + - + - + + + #oe_class_id_check# + + + + + + + + + + + + + + #CHECK (((id = 1) OR (id = 2)))# + + + ## + + + + + + + + + + + + + + - + @@ -9350,7 +9869,7 @@ - #partstax# + #orderitems# @@ -9426,10 +9945,10 @@ - # parts_id# + # id# - #integer# + #serial# @@ -9449,7 +9968,7 @@ - # chart_id# + # trans_id# #integer# @@ -9472,7 +9991,7 @@ - # taxcategory_id# + # parts_id# #integer# @@ -9493,116 +10012,58 @@ - + + + # description# + + + #text# + + - - - - + - - - - - + + + + + + + + + + + - - - - - - - - - - - - - - - - - - #partsvendor# - + + + # qty# + + + #numeric# + + - - ## - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + - # vendor_id# + # sellprice# - #integer# + #numeric# @@ -9622,10 +10083,10 @@ - # parts_id# + # discount# - #integer# + #numeric# @@ -9645,10 +10106,10 @@ - # partnumber# + # unit# - #text# + #character varying(5)# @@ -9668,10 +10129,10 @@ - # leadtime# + # project_id# - #smallint# + #integer# @@ -9691,7 +10152,30 @@ - # lastcost# + # reqdate# + + + #date# + + + + + + + + + + + + + + + + + + + + # ship# #numeric# @@ -9714,10 +10198,10 @@ - # curr# + # serialnumber# - #character(3)# + #text# @@ -9737,10 +10221,10 @@ - # entry_id# + # notes# - #serial# + #text# @@ -9771,7 +10255,7 @@ - + @@ -9788,7 +10272,7 @@ - #pricegroup# + #parts# @@ -9867,11 +10351,11 @@ # id# - #integer# + #serial# - #nextval('id'::regclass)# + @@ -9887,7 +10371,7 @@ - # pricegroup# + # partnumber# #text# @@ -9908,120 +10392,16 @@ - - - - - - + + + # description# + + + #text# + + - - - - - - - - - - - - - - - - - - - - - - - - #project# - - - - ## - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # id# - - - #integer# - - - - #nextval('id'::regclass)# + @@ -10037,10 +10417,10 @@ - # projectnumber# + # unit# - #text# + #character varying(5)# @@ -10060,10 +10440,10 @@ - # description# + # listprice# - #text# + #numeric# @@ -10083,10 +10463,10 @@ - # startdate# + # sellprice# - #date# + #numeric# @@ -10106,10 +10486,10 @@ - # enddate# + # lastcost# - #date# + #numeric# @@ -10129,14 +10509,14 @@ - # parts_id# + # priceupdate# - #integer# + #date# - + #('now'::text)::date# @@ -10152,7 +10532,7 @@ - # production# + # weight# #numeric# @@ -10175,7 +10555,7 @@ - # completed# + # onhand# #numeric# @@ -10198,10 +10578,10 @@ - # customer_id# + # notes# - #integer# + #text# @@ -10219,120 +10599,16 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - #recurring# - - - - ## - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # id# + # makemodel# - #integer# + #boolean# - + #false# @@ -10348,14 +10624,14 @@ - # reference# + # assembly# - #text# + #boolean# - + #false# @@ -10371,14 +10647,14 @@ - # startdate# + # alternate# - #date# + #boolean# - + #false# @@ -10394,10 +10670,10 @@ - # nextdate# + # rop# - #date# + #real# @@ -10417,10 +10693,10 @@ - # enddate# + # inventory_accno_id# - #date# + #integer# @@ -10440,10 +10716,10 @@ - # repeat# + # income_accno_id# - #smallint# + #integer# @@ -10463,10 +10739,10 @@ - # unit# + # expense_accno_id# - #character varying(6)# + #integer# @@ -10486,10 +10762,10 @@ - # howmany# + # bin# - #integer# + #text# @@ -10509,7 +10785,7 @@ - # payment# + # obsolete# #boolean# @@ -10530,116 +10806,58 @@ - + + + # bom# + + + #boolean# + + - - - - + #false# - - - - - + + + + + + + + + + + - - - - - - - - - - - - - - - - - - #recurringemail# - + + + # image# + + + #text# + + - - ## - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + - # id# + # drawing# - #integer# + #text# @@ -10659,7 +10877,7 @@ - # formname# + # microfiche# #text# @@ -10682,10 +10900,10 @@ - # format# + # partsgroup_id# - #text# + #integer# @@ -10705,10 +10923,33 @@ - # message# + # project_id# - #text# + #integer# + + + + + + + + + + + + + + + + + + + + # avgcost# + + + #numeric# @@ -10739,7 +10980,7 @@ - + @@ -10756,7 +10997,7 @@ - #recurringprint# + #partscustomer# @@ -10832,7 +11073,7 @@ - # id# + # parts_id# #integer# @@ -10855,10 +11096,10 @@ - # formname# + # customer_id# - #text# + #integer# @@ -10878,10 +11119,10 @@ - # format# + # pricegroup_id# - #text# + #integer# @@ -10901,10 +11142,10 @@ - # printer# + # pricebreak# - #text# + #numeric# @@ -10922,40 +11163,155 @@ - - - - - - + + + # sellprice# + + + #numeric# + + - - - - - + - - - - - - - - - - - - - - - - - - #shipto# - + + + + + + + + + + + - + + + # validfrom# + + + #date# + + + + + + + + + + + + + + + + + + + + # validto# + + + #date# + + + + + + + + + + + + + + + + + + + + # curr# + + + #character(3)# + + + + + + + + + + + + + + + + + + + + # entry_id# + + + #serial# + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + #partsgroup# + + + ## @@ -11028,10 +11384,10 @@ - # trans_id# + # id# - #integer# + #serial# @@ -11051,10 +11407,10 @@ - # shiptoname# + # partsgroup# - #character varying(64)# + #text# @@ -11072,12 +11428,116 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + #partstax# + + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - # shiptoaddress1# + # parts_id# - #character varying(32)# + #integer# @@ -11097,10 +11557,10 @@ - # shiptoaddress2# + # chart_id# - #character varying(32)# + #integer# @@ -11120,10 +11580,10 @@ - # shiptocity# + # taxcategory_id# - #character varying(32)# + #integer# @@ -11141,35 +11601,116 @@ - - - # shiptostate# - - - #character varying(32)# - - + - + + + + - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + #partsvendor# + + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - # shiptozipcode# + # entity_id# - #character varying(10)# + #integer# @@ -11189,10 +11730,10 @@ - # shiptocountry# + # parts_id# - #character varying(32)# + #integer# @@ -11212,10 +11753,10 @@ - # shiptocontact# + # partnumber# - #character varying(64)# + #text# @@ -11235,10 +11776,10 @@ - # shiptophone# + # leadtime# - #character varying(20)# + #smallint# @@ -11258,10 +11799,10 @@ - # shiptofax# + # lastcost# - #character varying(20)# + #numeric# @@ -11281,10 +11822,10 @@ - # shiptoemail# + # curr# - #text# + #character(3)# @@ -11338,7 +11879,7 @@ - + @@ -11355,11 +11896,11 @@ - #sic# + #person# - ## + # Every person, must have an entity ... _id. # @@ -11431,10 +11972,10 @@ - # code# + # id# - #character varying(6)# + #serial# @@ -11454,10 +11995,10 @@ - # sictype# + # entity_id# - #character(1)# + #integer# @@ -11477,7 +12018,30 @@ - # description# + # salutation_id# + + + #integer# + + + + + + + + + + + + + + + + + + + + # first_name# #text# @@ -11498,28 +12062,161 @@ - + + + # middle_name# + + + #text# + + - - - - + - - - - - + + + + + + + + + + + + + + + # last_name# + + + #text# + + + + + + + + + + + + + + + + + + + + # primary_location_id# + + + #integer# + + + + + + + + + + + + + + + + - - - - - - - - + + + + + + + + + #person_first_name_check# + + + + + + + + + + + + + + #CHECK ((first_name ~ '[[:alnum ... ext))# + + + ## + + + + + + + + + + + + + + #person_last_name_check# + + + + + + + + + + + + + + #CHECK ((last_name ~ '[[:alnum: ... ext))# + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -11528,7 +12225,7 @@ - #status# + #person_to_company# @@ -11604,7 +12301,7 @@ - # trans_id# + # location_id# #integer# @@ -11627,79 +12324,10 @@ - # formname# - - - #text# - - - - - - - - - - - - - - - - - - - - # printed# - - - #boolean# - - - - #false# - - - - - - - - - - - - - - - - # emailed# - - - #boolean# - - - - #false# - - - - - - - - - - - - - - - - # spoolfile# + # person_id# - #text# + #integer# @@ -11730,7 +12358,7 @@ - + @@ -11747,11 +12375,11 @@ - #tax# + #person_to_contact# - ## + # To keep track of the relationship ... dual # @@ -11823,7 +12451,7 @@ - # chart_id# + # person_id# #integer# @@ -11846,10 +12474,10 @@ - # rate# + # contact_class_id# - #numeric# + #integer# @@ -11869,7 +12497,7 @@ - # taxnumber# + # contact# #text# @@ -11890,40 +12518,16 @@ - - - # validto# - - - #date# - - - - + - - - - - - - - - - - + + + + - + - # pass# - - - #integer# - - - - - + #person_to_contact_contact_check# @@ -11934,45 +12538,33 @@ - - - - - # taxmodule_id# - - - #integer# - - - - #1# - - - - - - - - - - + + + + #CHECK ((contact ~ '[[:alnum:]_ ... ext))# + + + ## + + + + + + + + - - - - - - + @@ -11989,7 +12581,7 @@ - #taxcategory# + #person_to_entity# @@ -12065,10 +12657,10 @@ - # taxcategory_id# + # person_id# - #serial# + #integer# @@ -12088,10 +12680,10 @@ - # taxcategoryname# + # entity_id# - #text# + #integer# @@ -12111,10 +12703,10 @@ - # taxmodule_id# + # related_how# - #integer# + #text# @@ -12132,12 +12724,68 @@ + + + # created# + + + #date# + + + + #('now'::text)::date# + + + + + + + + + + + + + - + + + + + + + #person_to_entity_check# + + + + + + + + + + + + + + #CHECK ((entity_id <> person_id))# + + + ## + + + + + + + + + + + - @@ -12145,7 +12793,7 @@ - + @@ -12162,7 +12810,7 @@ - #taxmodule# + #pricegroup# @@ -12238,7 +12886,7 @@ - # taxmodule_id# + # id# #serial# @@ -12261,7 +12909,7 @@ - # taxmodulename# + # pricegroup# #text# @@ -12295,7 +12943,7 @@ - + @@ -12312,7 +12960,7 @@ - #transactions# + #project# @@ -12391,7 +13039,7 @@ # id# - #integer# + #serial# @@ -12411,7 +13059,7 @@ - # table_name# + # projectnumber# #text# @@ -12432,113 +13080,78 @@ - + + + # description# + + + #text# + + - - - - + - - - - - + + + + + + + + + + + - - - - - - - - - - - - - - - - - - #translation# - + + + # startdate# + + + #date# + + - - ## - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + - # trans_id# + # enddate# + + + #date# + + + + + + + + + + + + + + + + + + + + # parts_id# #integer# @@ -12561,10 +13174,10 @@ - # language_code# + # production# - #character varying(6)# + #numeric# @@ -12584,10 +13197,33 @@ - # description# + # completed# - #text# + #numeric# + + + + + + + + + + + + + + + + + + + + # customer_id# + + + #integer# @@ -12618,7 +13254,7 @@ - + @@ -12635,7 +13271,7 @@ - #vendor# + #recurring# @@ -12718,7 +13354,7 @@ - #nextval('id'::regclass)# + @@ -12734,10 +13370,10 @@ - # name# + # reference# - #character varying(64)# + #text# @@ -12757,10 +13393,10 @@ - # address1# + # startdate# - #character varying(32)# + #date# @@ -12780,10 +13416,10 @@ - # address2# + # nextdate# - #character varying(32)# + #date# @@ -12803,10 +13439,10 @@ - # city# + # enddate# - #character varying(32)# + #date# @@ -12826,10 +13462,10 @@ - # state# + # repeat# - #character varying(32)# + #smallint# @@ -12849,10 +13485,10 @@ - # zipcode# + # unit# - #character varying(10)# + #character varying(6)# @@ -12872,10 +13508,10 @@ - # country# + # howmany# - #character varying(32)# + #integer# @@ -12895,14 +13531,14 @@ - # contact# + # payment# - #character varying(64)# + #boolean# - + #false# @@ -12916,35 +13552,116 @@ - - - # phone# - - - #character varying(20)# - - + - + + + + - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + #recurringemail# + + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - # fax# + # id# - #character varying(20)# + #integer# @@ -12964,7 +13681,7 @@ - # email# + # formname# #text# @@ -12987,7 +13704,7 @@ - # notes# + # format# #text# @@ -13010,10 +13727,10 @@ - # terms# + # message# - #smallint# + #text# @@ -13031,35 +13748,116 @@ - - - # taxincluded# - - - #boolean# - - + - #false# + + + + - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + #recurringprint# + + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - # vendornumber# + # id# - #character varying(32)# + #integer# @@ -13079,7 +13877,7 @@ - # cc# + # formname# #text# @@ -13102,7 +13900,7 @@ - # bcc# + # format# #text# @@ -13125,10 +13923,10 @@ - # gifi_accno# + # printer# - #character varying(30)# + #text# @@ -13146,35 +13944,116 @@ - - - # business_id# - - - #integer# - - + - + + + + - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + #salutation# + + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - # taxnumber# + # id# - #character varying(32)# + #serial# @@ -13194,10 +14073,10 @@ - # sic_code# + # salutation# - #character varying(6)# + #text# @@ -13215,12 +14094,116 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + #shipto# + + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - # discount# + # trans_id# - #numeric# + #integer# @@ -13240,10 +14223,10 @@ - # creditlimit# + # shiptoname# - #numeric# + #character varying(64)# @@ -13263,10 +14246,10 @@ - # iban# + # shiptoaddress1# - #character varying(34)# + #character varying(32)# @@ -13286,10 +14269,10 @@ - # bic# + # shiptoaddress2# - #character varying(11)# + #character varying(32)# @@ -13309,10 +14292,10 @@ - # employee_id# + # shiptocity# - #integer# + #character varying(32)# @@ -13332,10 +14315,10 @@ - # language_code# + # shiptostate# - #character varying(6)# + #character varying(32)# @@ -13355,10 +14338,10 @@ - # pricegroup_id# + # shiptozipcode# - #integer# + #character varying(10)# @@ -13378,10 +14361,10 @@ - # curr# + # shiptocountry# - #character(3)# + #character varying(32)# @@ -13401,10 +14384,10 @@ - # startdate# + # shiptocontact# - #date# + #character varying(64)# @@ -13424,10 +14407,10 @@ - # enddate# + # shiptophone# - #date# + #character varying(20)# @@ -13445,12 +14428,81 @@ - - - - - - + + + # shiptofax# + + + #character varying(20)# + + + + + + + + + + + + + + + + + + + + # shiptoemail# + + + #text# + + + + + + + + + + + + + + + + + + + + # entry_id# + + + #serial# + + + + + + + + + + + + + + + + + + + + + + + @@ -13458,7 +14510,7 @@ - + @@ -13475,7 +14527,7 @@ - #vendortax# + #sic# @@ -13551,10 +14603,10 @@ - # vendor_id# + # code# - #integer# + #character varying(6)# @@ -13574,10 +14626,33 @@ - # chart_id# + # sictype# - #integer# + #character(1)# + + + + + + + + + + + + + + + + + + + + # description# + + + #text# @@ -13608,7 +14683,7 @@ - + @@ -13625,7 +14700,7 @@ - #warehouse# + #status# @@ -13701,14 +14776,14 @@ - # id# + # trans_id# #integer# - #nextval('id'::regclass)# + @@ -13724,7 +14799,76 @@ - # description# + # formname# + + + #text# + + + + + + + + + + + + + + + + + + + + # printed# + + + #boolean# + + + + #false# + + + + + + + + + + + + + + + + # emailed# + + + #boolean# + + + + #false# + + + + + + + + + + + + + + + + # spoolfile# #text# @@ -13746,172 +14890,2886 @@ - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + #tax# + + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + # chart_id# + + + #integer# + + + + + + + + + + + + + + + + + + + + # rate# + + + #numeric# + + + + + + + + + + + + + + + + + + + + # taxnumber# + + + #text# + + + + + + + + + + + + + + + + + + + + # validto# + + + #date# + + + + + + + + + + + + + + + + + + + + # pass# + + + #integer# + + + + + + + + + + + + + + + + + + + + # taxmodule_id# + + + #integer# + + + + #1# + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + #taxcategory# + + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + # taxcategory_id# + + + #serial# + + + + + + + + + + + + + + + + + + + + # taxcategoryname# + + + #text# + + + + + + + + + + + + + + + + + + + + # taxmodule_id# + + + #integer# + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + #taxmodule# + + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + # taxmodule_id# + + + #serial# + + + + + + + + + + + + + + + + + + + + # taxmodulename# + + + #text# + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + #transactions# + + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + # id# + + + #integer# + + + + + + + + + + + + + + + + + + + + # table_name# + + + #text# + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + #translation# + + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + # trans_id# + + + #integer# + + + + + + + + + + + + + + + + + + + + # language_code# + + + #character varying(6)# + + + + + + + + + + + + + + + + + + + + # description# + + + #text# + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + #vendor# + + + + # Now a meta data table # + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + # id# + + + #serial# + + + + + + + + + + + + + + + + + + + + # entity_id# + + + #integer# + + + + + + + + + + + + + + + + + + + + # terms# + + + #smallint# + + + + + + + + + + + + + + + + + + + + # taxincluded# + + + #boolean# + + + + #false# + + + + + + + + + + + + + + + + # vendornumber# + + + #character varying(32)# + + + + + + + + + + + + + + + + + + + + # cc# + + + #text# + + + + + + + + + + + + + + + + + + + + # bcc# + + + #text# + + + + + + + + + + + + + + + + + + + + # gifi_accno# + + + #character varying(30)# + + + + + + + + + + + + + + + + + + + + # business_id# + + + #integer# + + + + + + + + + + + + + + + + + + + + # taxnumber# + + + #character varying(32)# + + + + + + + + + + + + + + + + + + + + # sic_code# + + + #character varying(6)# + + + + + + + + + + + + + + + + + + + + # discount# + + + #numeric# + + + + + + + + + + + + + + + + + + + + # creditlimit# + + + #numeric# + + + + + + + + + + + + + + + + + + + + # iban# + + + #character varying(34)# + + + + + + + + + + + + + + + + + + + + # bic# + + + #character varying(11)# + + + + + + + + + + + + + + + + + + + + # language_code# + + + #character varying(6)# + + + + + + + + + + + + + + + + + + + + # pricegroup_id# + + + #integer# + + + + + + + + + + + + + + + + + + + + # curr# + + + #character(3)# + + + + + + + + + + + + + + + + + + + + # startdate# + + + #date# + + + + + + + + + + + + + + + + + + + + # enddate# + + + #date# + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + #vendortax# + + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + # vendor_id# + + + #integer# + + + + + + + + + + + + + + + + + + + + # chart_id# + + + #integer# + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + #warehouse# + + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + # id# + + + #serial# + + + + + + + + + + + + + + + + + + + + # description# + + + #text# + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + #yearend# + + + + ## + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + # trans_id# + + + #integer# + + + + + + + + + + + + + + + + + + + + # transdate# + + + #date# + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + #acc_trans_chart_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #ap_entity_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #ap_person_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #ar_entity_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #ar_person_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #audittrail_person_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #company_entity_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #company_entity_class_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #company_primary_location_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #company_to_contact_company_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #company_to_contact_contact_class_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #company_to_entity_company_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #company_to_entity_entity_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #company_to_location_location_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #company_to_location_company_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #custom_field_catalog_table_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #customer_entity_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #employee_entity_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #entity_entity_class_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #entity_class_to_entity_entity_class_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #entity_class_to_entity_entity_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #entity_other_name_entity_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #gl_person_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #inventory_person_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #jcitems_person_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #location_country_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #oe_entity_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #oe_person_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #oe_oe_class_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #partstax_parts_id_fkey# + + + + + + + + + + + + + + + + + + + + + + + + + + #partstax_chart_id_fkey# + + + - - - - + + - + + + + - + - + - + - - + + + - - + + #partstax_taxcategory_id_fkey# - - + + - - #yearend# + + + + + + + - - ## + + + - - + + - - + + + - - + + #partsvendor_entity_id_fkey# - - + + - - + + - - + + + + + + + + + - - + + - - + + + - - + + #person_entity_id_fkey# - + + + + - - + + + + + + + + + - - + + - - + + + - - + + #person_salutation_id_fkey# - - + + - - + + - - + + + + + + + + + - - + + - - + + + - - + + #person_primary_location_id_fkey# - - + + - - + + - - - - - # trans_id# - - - #integer# - - - - - - - - - - - - - - - - - - - - # transdate# - - - #date# - - - - - - - - - - - - - - - - + + + + + + + + - - - + + - - - - + + + - + + #person_to_company_location_id_fkey# + + + + + + + + + + + - - - - + @@ -13923,7 +17781,7 @@ - #acc_trans_chart_id_fkey# + #person_to_company_person_id_fkey# @@ -13932,12 +17790,12 @@ - - + + - + @@ -13949,7 +17807,7 @@ - #custom_field_catalog_table_id_fkey# + #person_to_contact_person_id_fkey# @@ -13958,12 +17816,12 @@ - - + + - + @@ -13975,7 +17833,7 @@ - #partstax_parts_id_fkey# + #person_to_contact_contact_class_id_fkey# @@ -13984,12 +17842,12 @@ - - + + - + @@ -14001,7 +17859,7 @@ - #partstax_chart_id_fkey# + #person_to_entity_person_id_fkey# @@ -14010,12 +17868,12 @@ - - + + - + @@ -14027,7 +17885,7 @@ - #partstax_taxcategory_id_fkey# + #person_to_entity_entity_id_fkey# @@ -14036,12 +17894,12 @@ - - + + - + @@ -14062,12 +17920,12 @@ - + - + @@ -14088,12 +17946,12 @@ - - + + - + @@ -14114,8 +17972,34 @@ - - + + + + + + + + + + + + + + + + + + #vendor_entity_id_fkey# + + + + + + + + + + diff --git a/doc/database/ledgersmb.dot b/doc/database/ledgersmb.dot index 96c7749e..9913c1c1 100644 --- a/doc/database/ledgersmb.dot +++ b/doc/database/ledgersmb.dot @@ -13,67 +13,99 @@ edge [ "acc_trans" [shape = plaintext, label = <
\N
trans_id integer
chart_id integer FK
amount numeric
transdate date
source text
cleared boolean
fx_transaction boolean
project_id integer
memo text
invoice_id integer
entry_id serial PK
> ]; -"ap" [shape = plaintext, label = <
\N
id integer PK
invnumber text
transdate date
vendor_id integer
taxincluded boolean
amount numeric
netamount numeric
paid numeric
datepaid date
duedate date
invoice boolean
ordnumber text
curr character(3)
notes text
employee_id integer
till character varying(20)
quonumber text
intnotes text
department_id integer
shipvia text
language_code character varying(6)
ponumber text
shippingpoint text
terms smallint
> ]; +"ap" [shape = plaintext, label = <
\N
id serial PK
invnumber text
transdate date
entity_id integer FK
taxincluded boolean
amount numeric
netamount numeric
paid numeric
datepaid date
duedate date
invoice boolean
ordnumber text
curr character(3)
notes text
person_id integer FK
till character varying(20)
quonumber text
intnotes text
department_id integer
shipvia text
language_code character varying(6)
ponumber text
shippingpoint text
terms smallint
> ]; -"ar" [shape = plaintext, label = <
\N
id integer PK
invnumber text
transdate date
customer_id integer
taxincluded boolean
amount numeric
netamount numeric
paid numeric
datepaid date
duedate date
invoice boolean
shippingpoint text
terms smallint
notes text
curr character(3)
ordnumber text
employee_id integer
till character varying(20)
quonumber text
intnotes text
department_id integer
shipvia text
language_code character varying(6)
ponumber text
> ]; +"ar" [shape = plaintext, label = <
\N
id serial PK
invnumber text
transdate date
entity_id integer FK
taxincluded boolean
amount numeric
netamount numeric
paid numeric
datepaid date
duedate date
invoice boolean
shippingpoint text
terms smallint
notes text
curr character(3)
ordnumber text
person_id integer FK
till character varying(20)
quonumber text
intnotes text
department_id integer
shipvia text
language_code character varying(6)
ponumber text
> ]; "assembly" [shape = plaintext, label = <
\N
id integer PK
parts_id integer PK
qty numeric
bom boolean
adj boolean
> ]; -"audittrail" [shape = plaintext, label = <
\N
trans_id integer
tablename text
reference text
formname text
action text
transdate timestamp without time zone
employee_id integer
entry_id bigserial PK
> ]; +"audittrail" [shape = plaintext, label = <
\N
trans_id integer
tablename text
reference text
formname text
action text
transdate timestamp without time zone
person_id integer FK
entry_id bigserial PK
> ]; -"business" [shape = plaintext, label = <
\N
id integer PK
description text
discount numeric
> ]; +"business" [shape = plaintext, label = <
\N
id serial PK
description text
discount numeric
> ]; -"chart" [shape = plaintext, label = <
\N
id integer PK
accno text
description text
charttype character(1)
category character(1)
link text
gifi_accno text
contra boolean
> ]; +"chart" [shape = plaintext, label = <
\N
id serial PK
accno text
description text
charttype character(1)
category character(1)
link text
gifi_accno text
contra boolean
> ]; + +"company" [shape = plaintext, label = <
\N
id serial
entity_id integer FK
legal_name text PK
entity_class_id integer FK
primary_location_id integer PK
tax_id text
> ]; + +"company_to_contact" [shape = plaintext, label = <
\N
company_id integer PK FK
contact_class_id integer PK FK
contact text PK
> ]; + +"company_to_entity" [shape = plaintext, label = <
\N
company_id integer PK FK
entity_id integer PK FK
related_how text
created date
> ]; + +"company_to_location" [shape = plaintext, label = <
\N
location_id integer PK FK
company_id integer PK FK
> ]; + +"contact_class" [shape = plaintext, label = <
\N
id serial
class text PK
> ]; + +"country" [shape = plaintext, label = <
\N
id serial PK
name text
short_name text
itu text
> ]; "custom_field_catalog" [shape = plaintext, label = <
\N
field_id serial PK
table_id integer FK
field_name text
> ]; "custom_table_catalog" [shape = plaintext, label = <
\N
table_id serial PK
extends text
table_name text
> ]; -"customer" [shape = plaintext, label = <
\N
id integer PK
name character varying(64)
address1 character varying(32)
address2 character varying(32)
city character varying(32)
state character varying(32)
zipcode character varying(10)
country character varying(32)
contact character varying(64)
phone character varying(20)
fax character varying(20)
email text
notes text
discount numeric
taxincluded boolean
creditlimit numeric
terms smallint
customernumber character varying(32)
cc text
bcc text
business_id integer
taxnumber character varying(32)
sic_code character varying(6)
iban character varying(34)
bic character varying(11)
employee_id integer
language_code character varying(6)
pricegroup_id integer
curr character(3)
startdate date
enddate date
> ]; +"customer" [shape = plaintext, label = <
\N
id serial PK
entity_id integer FK
discount numeric
taxincluded boolean
creditlimit numeric
terms smallint
customernumber character varying(32)
cc text
bcc text
business_id integer
sic_code character varying(6)
iban character varying(34)
bic character varying(11)
language_code character varying(6)
pricegroup_id integer
curr character(3)
startdate date
enddate date
invoice_notes text
> ]; "customertax" [shape = plaintext, label = <
\N
customer_id integer PK
chart_id integer PK
> ]; "defaults" [shape = plaintext, label = <
\N
setting_key text PK
value text
> ]; -"department" [shape = plaintext, label = <
\N
id integer PK
description text
role character(1)
> ]; +"department" [shape = plaintext, label = <
\N
id serial PK
description text
role character(1)
> ]; "dpt_trans" [shape = plaintext, label = <
\N
trans_id integer PK
department_id integer
> ]; -"employee" [shape = plaintext, label = <
\N
id integer PK
login text
name character varying(64)
address1 character varying(32)
address2 character varying(32)
city character varying(32)
state character varying(32)
zipcode character varying(10)
country character varying(32)
workphone character varying(20)
homephone character varying(20)
startdate date
enddate date
notes text
role character varying(20)
sales boolean
email text
ssn character varying(20)
iban character varying(34)
bic character varying(11)
managerid integer
employeenumber character varying(32)
dob date
> ]; +"employee" [shape = plaintext, label = <
\N
id serial PK
entity_id integer FK
login text
startdate date
enddate date
notes text
role character varying(20)
sales boolean
ssn character varying(20)
iban character varying(34)
bic character varying(11)
managerid integer
employeenumber character varying(32)
dob date
> ]; + +"entity" [shape = plaintext, label = <
\N
id serial PK
name text
entity_class integer FK
> ]; + +"entity_class" [shape = plaintext, label = <
\N
id serial PK
class text
active boolean
> ]; + +"entity_class_to_entity" [shape = plaintext, label = <
\N
entity_class_id integer PK FK
entity_id integer PK FK
> ]; + +"entity_other_name" [shape = plaintext, label = <
\N
entity_id integer PK FK
other_name text PK
> ]; "exchangerate" [shape = plaintext, label = <
\N
curr character(3) PK
transdate date PK
buy numeric
sell numeric
> ]; "gifi" [shape = plaintext, label = <
\N
accno text PK
description text
> ]; -"gl" [shape = plaintext, label = <
\N
id integer PK
reference text
description text
transdate date
employee_id integer
notes text
department_id integer
> ]; +"gl" [shape = plaintext, label = <
\N
id serial PK
reference text
description text
transdate date
person_id integer FK
notes text
department_id integer
> ]; -"inventory" [shape = plaintext, label = <
\N
warehouse_id integer
parts_id integer
trans_id integer
orderitems_id integer
qty numeric
shippingdate date
employee_id integer
entry_id serial PK
> ]; +"inventory" [shape = plaintext, label = <
\N
warehouse_id integer
parts_id integer
trans_id integer
orderitems_id integer
qty numeric
shippingdate date
person_id integer FK
entry_id serial PK
> ]; -"invoice" [shape = plaintext, label = <
\N
id integer PK
trans_id integer
parts_id integer
description text
qty integer
allocated integer
sellprice numeric
fxsellprice numeric
discount real
assemblyitem boolean
unit character varying(5)
project_id integer
deliverydate date
serialnumber text
notes text
> ]; +"invoice" [shape = plaintext, label = <
\N
id serial PK
trans_id integer
parts_id integer
description text
qty integer
allocated integer
sellprice numeric
fxsellprice numeric
discount real
assemblyitem boolean
unit character varying(5)
project_id integer
deliverydate date
serialnumber text
notes text
> ]; -"jcitems" [shape = plaintext, label = <
\N
id integer PK
project_id integer
parts_id integer
description text
qty numeric
allocated numeric
sellprice numeric
fxsellprice numeric
serialnumber text
checkedin timestamp with time zone
checkedout timestamp with time zone
employee_id integer
notes text
> ]; +"jcitems" [shape = plaintext, label = <
\N
id serial PK
project_id integer
parts_id integer
description text
qty numeric
allocated numeric
sellprice numeric
fxsellprice numeric
serialnumber text
checkedin timestamp with time zone
checkedout timestamp with time zone
person_id integer FK
notes text
> ]; "language" [shape = plaintext, label = <
\N
code character varying(6) PK
description text
> ]; +"location" [shape = plaintext, label = <
\N
id serial PK
line_one text
line_two text
line_three text
city_province text
country_id integer FK
mail_code text
> ]; + "makemodel" [shape = plaintext, label = <
\N
parts_id integer PK
make text
model text
> ]; -"oe" [shape = plaintext, label = <
\N
id integer PK
ordnumber text
transdate date
vendor_id integer
customer_id integer
amount numeric
netamount numeric
reqdate date
taxincluded boolean
shippingpoint text
notes text
curr character(3)
employee_id integer
closed boolean
quotation boolean
quonumber text
intnotes text
department_id integer
shipvia text
language_code character varying(6)
ponumber text
terms smallint
> ]; +"oe" [shape = plaintext, label = <
\N
id serial PK
ordnumber text
transdate date
entity_id integer FK
amount numeric
netamount numeric
reqdate date
taxincluded boolean
shippingpoint text
notes text
curr character(3)
person_id integer FK
closed boolean
quotation boolean
quonumber text
intnotes text
department_id integer
shipvia text
language_code character varying(6)
ponumber text
terms smallint
oe_class_id integer FK
> ]; -"orderitems" [shape = plaintext, label = <
\N
id integer PK
trans_id integer
parts_id integer
description text
qty numeric
sellprice numeric
discount numeric
unit character varying(5)
project_id integer
reqdate date
ship numeric
serialnumber text
notes text
> ]; +"oe_class" [shape = plaintext, label = <
\N
id smallint
oe_class text PK
> ]; -"parts" [shape = plaintext, label = <
\N
id integer PK
partnumber text
description text
unit character varying(5)
listprice numeric
sellprice numeric
lastcost numeric
priceupdate date
weight numeric
onhand numeric
notes text
makemodel boolean
assembly boolean
alternate boolean
rop real
inventory_accno_id integer
income_accno_id integer
expense_accno_id integer
bin text
obsolete boolean
bom boolean
image text
drawing text
microfiche text
partsgroup_id integer
project_id integer
avgcost numeric
> ]; +"orderitems" [shape = plaintext, label = <
\N
id serial PK
trans_id integer
parts_id integer
description text
qty numeric
sellprice numeric
discount numeric
unit character varying(5)
project_id integer
reqdate date
ship numeric
serialnumber text
notes text
> ]; + +"parts" [shape = plaintext, label = <
\N
id serial PK
partnumber text
description text
unit character varying(5)
listprice numeric
sellprice numeric
lastcost numeric
priceupdate date
weight numeric
onhand numeric
notes text
makemodel boolean
assembly boolean
alternate boolean
rop real
inventory_accno_id integer
income_accno_id integer
expense_accno_id integer
bin text
obsolete boolean
bom boolean
image text
drawing text
microfiche text
partsgroup_id integer
project_id integer
avgcost numeric
> ]; "partscustomer" [shape = plaintext, label = <
\N
parts_id integer
customer_id integer
pricegroup_id integer
pricebreak numeric
sellprice numeric
validfrom date
validto date
curr character(3)
entry_id serial PK
> ]; -"partsgroup" [shape = plaintext, label = <
\N
id integer PK
partsgroup text
> ]; +"partsgroup" [shape = plaintext, label = <
\N
id serial PK
partsgroup text
> ]; "partstax" [shape = plaintext, label = <
\N
parts_id integer PK FK
chart_id integer PK FK
taxcategory_id integer FK
> ]; -"partsvendor" [shape = plaintext, label = <
\N
vendor_id integer
parts_id integer
partnumber text
leadtime smallint
lastcost numeric
curr character(3)
entry_id serial PK
> ]; +"partsvendor" [shape = plaintext, label = <
\N
entity_id integer FK
parts_id integer
partnumber text
leadtime smallint
lastcost numeric
curr character(3)
entry_id serial PK
> ]; + +"person" [shape = plaintext, label = <
\N
id serial PK
entity_id integer FK
salutation_id integer FK
first_name text
middle_name text
last_name text
primary_location_id integer FK
> ]; -"pricegroup" [shape = plaintext, label = <
\N
id integer PK
pricegroup text
> ]; +"person_to_company" [shape = plaintext, label = <
\N
location_id integer PK FK
person_id integer PK FK
> ]; -"project" [shape = plaintext, label = <
\N
id integer PK
projectnumber text
description text
startdate date
enddate date
parts_id integer
production numeric
completed numeric
customer_id integer
> ]; +"person_to_contact" [shape = plaintext, label = <
\N
person_id integer PK FK
contact_class_id integer PK FK
contact text PK
> ]; + +"person_to_entity" [shape = plaintext, label = <
\N
person_id integer PK FK
entity_id integer PK FK
related_how text
created date
> ]; + +"pricegroup" [shape = plaintext, label = <
\N
id serial PK
pricegroup text
> ]; + +"project" [shape = plaintext, label = <
\N
id serial PK
projectnumber text
description text
startdate date
enddate date
parts_id integer
production numeric
completed numeric
customer_id integer
> ]; "recurring" [shape = plaintext, label = <
\N
id integer PK
reference text
startdate date
nextdate date
enddate date
repeat smallint
unit character varying(6)
howmany integer
payment boolean
> ]; @@ -81,6 +113,8 @@ edge [ "recurringprint" [shape = plaintext, label = <
\N
id integer PK
formname text
format text
printer text
> ]; +"salutation" [shape = plaintext, label = <
\N
id serial
salutation text PK
> ]; + "shipto" [shape = plaintext, label = <
\N
trans_id integer
shiptoname character varying(64)
shiptoaddress1 character varying(32)
shiptoaddress2 character varying(32)
shiptocity character varying(32)
shiptostate character varying(32)
shiptozipcode character varying(10)
shiptocountry character varying(32)
shiptocontact character varying(64)
shiptophone character varying(20)
shiptofax character varying(20)
shiptoemail text
entry_id serial PK
> ]; "sic" [shape = plaintext, label = <
\N
code character varying(6) PK
sictype character(1)
description text
> ]; @@ -97,22 +131,60 @@ edge [ "translation" [shape = plaintext, label = <
\N
trans_id integer PK
language_code character varying(6) PK
description text
> ]; -"vendor" [shape = plaintext, label = <
\N
id integer PK
name character varying(64)
address1 character varying(32)
address2 character varying(32)
city character varying(32)
state character varying(32)
zipcode character varying(10)
country character varying(32)
contact character varying(64)
phone character varying(20)
fax character varying(20)
email text
notes text
terms smallint
taxincluded boolean
vendornumber character varying(32)
cc text
bcc text
gifi_accno character varying(30)
business_id integer
taxnumber character varying(32)
sic_code character varying(6)
discount numeric
creditlimit numeric
iban character varying(34)
bic character varying(11)
employee_id integer
language_code character varying(6)
pricegroup_id integer
curr character(3)
startdate date
enddate date
> ]; +"vendor" [shape = plaintext, label = <
\N
id serial PK
entity_id integer FK
terms smallint
taxincluded boolean
vendornumber character varying(32)
cc text
bcc text
gifi_accno character varying(30)
business_id integer
taxnumber character varying(32)
sic_code character varying(6)
discount numeric
creditlimit numeric
iban character varying(34)
bic character varying(11)
language_code character varying(6)
pricegroup_id integer
curr character(3)
startdate date
enddate date
> ]; "vendortax" [shape = plaintext, label = <
\N
vendor_id integer PK
chart_id integer PK
> ]; -"warehouse" [shape = plaintext, label = <
\N
id integer PK
description text
> ]; +"warehouse" [shape = plaintext, label = <
\N
id serial PK
description text
> ]; "yearend" [shape = plaintext, label = <
\N
trans_id integer PK
transdate date
> ]; "acc_trans":rtcol2 -> "chart":ltcol1 [label="acc_trans_chart_id_fkey"]; +"ap":rtcol4 -> "entity":ltcol1 [label="ap_entity_id_fkey"]; +"ap":rtcol15 -> "person":ltcol1 [label="ap_person_id_fkey"]; +"ar":rtcol4 -> "entity":ltcol1 [label="ar_entity_id_fkey"]; +"ar":rtcol17 -> "person":ltcol1 [label="ar_person_id_fkey"]; +"audittrail":rtcol7 -> "person":ltcol1 [label="audittrail_person_id_fkey"]; +"company":rtcol2 -> "entity":ltcol1 [label="company_entity_id_fkey"]; +"company":rtcol4 -> "entity_class":ltcol1 [label="company_entity_class_id_fkey"]; +"company":rtcol5 -> "location":ltcol1 [label="company_primary_location_id_fkey"]; +"company_to_contact":rtcol1 -> "company":ltcol1 [label="company_to_contact_company_id_fkey"]; +"company_to_contact":rtcol2 -> "contact_class":ltcol1 [label="company_to_contact_contact_class_id_fkey"]; +"company_to_entity":rtcol1 -> "company":ltcol1 [label="company_to_entity_company_id_fkey"]; +"company_to_entity":rtcol2 -> "entity":ltcol1 [label="company_to_entity_entity_id_fkey"]; +"company_to_location":rtcol1 -> "location":ltcol1 [label="company_to_location_location_id_fkey"]; +"company_to_location":rtcol2 -> "company":ltcol1 [label="company_to_location_company_id_fkey"]; "custom_field_catalog":rtcol2 -> "custom_table_catalog":ltcol1 [label="custom_field_catalog_table_id_fkey"]; +"customer":rtcol2 -> "entity":ltcol1 [label="customer_entity_id_fkey"]; +"employee":rtcol2 -> "entity":ltcol1 [label="employee_entity_id_fkey"]; +"entity":rtcol3 -> "entity_class":ltcol1 [label="entity_entity_class_fkey"]; +"entity_class_to_entity":rtcol1 -> "entity_class":ltcol1 [label="entity_class_to_entity_entity_class_id_fkey"]; +"entity_class_to_entity":rtcol2 -> "entity":ltcol1 [label="entity_class_to_entity_entity_id_fkey"]; +"entity_other_name":rtcol1 -> "entity":ltcol1 [label="entity_other_name_entity_id_fkey"]; +"gl":rtcol5 -> "person":ltcol1 [label="gl_person_id_fkey"]; +"inventory":rtcol7 -> "person":ltcol1 [label="inventory_person_id_fkey"]; +"jcitems":rtcol12 -> "person":ltcol1 [label="jcitems_person_id_fkey"]; +"location":rtcol6 -> "country":ltcol1 [label="location_country_id_fkey"]; +"oe":rtcol4 -> "entity":ltcol1 [label="oe_entity_id_fkey"]; +"oe":rtcol12 -> "person":ltcol1 [label="oe_person_id_fkey"]; +"oe":rtcol22 -> "oe_class":ltcol1 [label="oe_oe_class_id_fkey"]; "partstax":rtcol1 -> "parts":ltcol1 [label="partstax_parts_id_fkey"]; "partstax":rtcol2 -> "chart":ltcol1 [label="partstax_chart_id_fkey"]; "partstax":rtcol3 -> "taxcategory":ltcol1 [label="partstax_taxcategory_id_fkey"]; +"partsvendor":rtcol1 -> "entity":ltcol1 [label="partsvendor_entity_id_fkey"]; +"person":rtcol2 -> "entity":ltcol1 [label="person_entity_id_fkey"]; +"person":rtcol3 -> "salutation":ltcol1 [label="person_salutation_id_fkey"]; +"person":rtcol7 -> "location":ltcol1 [label="person_primary_location_id_fkey"]; +"person_to_company":rtcol1 -> "location":ltcol1 [label="person_to_company_location_id_fkey"]; +"person_to_company":rtcol2 -> "person":ltcol1 [label="person_to_company_person_id_fkey"]; +"person_to_contact":rtcol1 -> "person":ltcol1 [label="person_to_contact_person_id_fkey"]; +"person_to_contact":rtcol2 -> "contact_class":ltcol1 [label="person_to_contact_contact_class_id_fkey"]; +"person_to_entity":rtcol1 -> "person":ltcol1 [label="person_to_entity_person_id_fkey"]; +"person_to_entity":rtcol2 -> "entity":ltcol1 [label="person_to_entity_entity_id_fkey"]; "tax":rtcol1 -> "chart":ltcol1 [label="tax_chart_id_fkey"]; "tax":rtcol6 -> "taxmodule":ltcol1 [label="tax_taxmodule_id_fkey"]; "taxcategory":rtcol3 -> "taxmodule":ltcol1 [label="taxcategory_taxmodule_id_fkey"]; +"vendor":rtcol2 -> "entity":ltcol1 [label="vendor_entity_id_fkey"]; } diff --git a/doc/database/ledgersmb.html b/doc/database/ledgersmb.html index 1011d507..078a1434 100644 --- a/doc/database/ledgersmb.html +++ b/doc/database/ledgersmb.html @@ -4,7 +4,7 @@ - Index for ledgersmb + Index for lsmb13-new