llx_accounting_account.sql 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. -- ============================================================================
  2. -- Copyright (C) 2004-2006 Laurent Destailleur <eldy@users.sourceforge.net>
  3. -- Copyright (C) 2014 Juanjo Menent <jmenent@2byte.es>
  4. -- Copyright (C) 2016 Alexandre Spangaro <aspangaro.dolibarr@gmail.com>
  5. --
  6. -- This program is free software; you can redistribute it and/or modify
  7. -- it under the terms of the GNU General Public License as published by
  8. -- the Free Software Foundation; either version 3 of the License, or
  9. -- (at your option) any later version.
  10. --
  11. -- This program is distributed in the hope that it will be useful,
  12. -- but WITHOUT ANY WARRANTY; without even the implied warranty of
  13. -- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  14. -- GNU General Public License for more details.
  15. --
  16. -- You should have received a copy of the GNU General Public License
  17. -- along with this program. If not, see <http://www.gnu.org/licenses/>.
  18. --
  19. -- Table of "accounts" for accountancy expert module
  20. -- ============================================================================
  21. create table llx_accounting_account
  22. (
  23. rowid integer AUTO_INCREMENT PRIMARY KEY,
  24. entity integer DEFAULT 1 NOT NULL,
  25. datec datetime,
  26. tms timestamp,
  27. fk_pcg_version varchar(32) NOT NULL,
  28. pcg_type varchar(20) NOT NULL,
  29. pcg_subtype varchar(20) NOT NULL,
  30. account_number varchar(32) NOT NULL,
  31. account_parent integer DEFAULT 0, -- Hierarchic parent
  32. label varchar(255) NOT NULL,
  33. fk_accounting_category integer DEFAULT 0,
  34. fk_user_author integer DEFAULT NULL,
  35. fk_user_modif integer DEFAULT NULL,
  36. active tinyint DEFAULT 1 NOT NULL
  37. )ENGINE=innodb;