Fix: Oubli cl sur table des dpartements
This commit is contained in:
parent
6768f85bef
commit
9e548ffc69
26
mysql/tables/llx_c_departements.key.sql
Normal file
26
mysql/tables/llx_c_departements.key.sql
Normal file
@ -0,0 +1,26 @@
|
||||
-- ============================================================================
|
||||
-- Copyright (C) 2005 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
--
|
||||
-- This program is free software; you can redistribute it and/or modify
|
||||
-- it under the terms of the GNU General Public License as published by
|
||||
-- the Free Software Foundation; either version 2 of the License, or
|
||||
-- (at your option) any later version.
|
||||
--
|
||||
-- This program is distributed in the hope that it will be useful,
|
||||
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
-- GNU General Public License for more details.
|
||||
--
|
||||
-- You should have received a copy of the GNU General Public License
|
||||
-- along with this program; if not, write to the Free Software
|
||||
-- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
--
|
||||
-- $Id$
|
||||
-- $Source$
|
||||
--
|
||||
-- ============================================================================
|
||||
|
||||
|
||||
ALTER TABLE llx_c_departements ADD UNIQUE uk_departements (code_departement,fk_region);
|
||||
|
||||
ALTER TABLE llx_c_departements ADD INDEX idx_departements_fk_region (fk_region);
|
||||
@ -30,9 +30,7 @@ create table llx_c_departements
|
||||
tncc integer,
|
||||
ncc varchar(50),
|
||||
nom varchar(50),
|
||||
active tinyint DEFAULT 1 NOT NULL,
|
||||
|
||||
key (fk_region)
|
||||
active tinyint DEFAULT 1 NOT NULL
|
||||
)type=innodb;
|
||||
|
||||
|
||||
|
||||
30
pgsql/tables/llx_c_departements.key.sql
Normal file
30
pgsql/tables/llx_c_departements.key.sql
Normal file
@ -0,0 +1,30 @@
|
||||
-- Generated from dolibarr_mysql2pgsql
|
||||
-- (c) 2004, PostgreSQL Inc.
|
||||
-- (c) 2005, Laurent Destailleur.
|
||||
|
||||
-- ============================================================================
|
||||
-- Copyright (C) 2005 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
--
|
||||
-- This program is free software; you can redistribute it and/or modify
|
||||
-- it under the terms of the GNU General Public License as published by
|
||||
-- the Free Software Foundation; either version 2 of the License, or
|
||||
-- (at your option) any later version.
|
||||
--
|
||||
-- This program is distributed in the hope that it will be useful,
|
||||
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
-- GNU General Public License for more details.
|
||||
--
|
||||
-- You should have received a copy of the GNU General Public License
|
||||
-- along with this program; if not, write to the Free Software
|
||||
-- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
--
|
||||
-- $Id$
|
||||
-- $Source$
|
||||
--
|
||||
-- ============================================================================
|
||||
|
||||
|
||||
ALTER TABLE llx_c_departements ADD UNIQUE uk_departements (code_departement,fk_region);
|
||||
|
||||
ALTER TABLE llx_c_departements ADD INDEX idx_departements_fk_region (fk_region);
|
||||
@ -25,7 +25,6 @@
|
||||
--
|
||||
-- ========================================================================
|
||||
|
||||
|
||||
create table llx_c_departements
|
||||
(
|
||||
rowid SERIAL PRIMARY KEY,
|
||||
@ -38,7 +37,5 @@ create table llx_c_departements
|
||||
"active" smallint DEFAULT 1 NOT NULL
|
||||
);
|
||||
|
||||
CREATE INDEX idx_llx_c_departements_fk_region ON llx_c_departements (fk_region);
|
||||
|
||||
|
||||
|
||||
|
||||
@ -25,4 +25,5 @@
|
||||
-- ========================================================================
|
||||
|
||||
|
||||
ALTER TABLE llx_c_regions ADD CONSTRAINT c_regions_fk_pays FOREIGN KEY (fk_pays) REFERENCES llx_c_pays (rowid);
|
||||
ALTER TABLE llx_c_regions ADD INDEX idx_c_regions_fk_pays (fk_pays);
|
||||
ALTER TABLE llx_c_regions ADD CONSTRAINT c_regions_fk_pays FOREIGN KEY (fk_pays) REFERENCES llx_c_pays (rowid);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user