nouvelle version des tables posgtresql

beautification du code, tout les parametres en MAJUSCULES
This commit is contained in:
opensides
2004-10-09 10:47:16 +00:00
parent 595958d1e8
commit cacc392b85
45 changed files with 92 additions and 96 deletions

View File

@@ -25,7 +25,7 @@ create table llx_c_chargesociales
(
id integer PRIMARY KEY,
libelle varchar(80),
deductible smallint NOT NULL DEFAULT 0,
deductible smallint DEFAULT 0 NOT NULL,
active tinyint DEFAULT 1 NOT NULL
)type=innodb;

View File

@@ -27,7 +27,7 @@ create table llx_c_forme_juridique
code varchar(12) UNIQUE NOT NULL,
fk_pays integer NOT NULL,
libelle varchar(255),
active tinyint default 1 NOT NULL
active tinyint DEFAULT 1 NOT NULL
)type=innodb;

View File

@@ -33,7 +33,7 @@ create table llx_c_paiement
code varchar(6) UNIQUE NOT NULL,
libelle varchar(30),
type smallint,
active tinyint default 1 NOT NULL
active tinyint DEFAULT 1 NOT NULL
)type=innodb;

View File

@@ -26,7 +26,7 @@ create table llx_c_pays
rowid integer PRIMARY KEY,
code varchar(6) UNIQUE NOT NULL,
libelle varchar(25) NOT NULL,
active tinyint default 1 NOT NULL
active tinyint DEFAULT 1 NOT NULL
)type=innodb;

View File

@@ -24,8 +24,8 @@
create table llx_c_propalst
(
id smallint PRIMARY KEY,
code varchar(12) UNIQUE NOT NULL,
code varchar(12) UNIQUE NOT NULL,
label varchar(30),
active tinyint default 1 NOT NULL
active tinyint DEFAULT 1 NOT NULL
)type=innodb;

View File

@@ -29,6 +29,6 @@ create table llx_c_regions
cheflieu varchar(7),
tncc integer,
nom varchar(50),
active tinyint default 1 NOT NULL
active tinyint DEFAULT 1 NOT NULL
)type=innodb;

View File

@@ -2,9 +2,6 @@
-- Copyright (C) 2001-2002,2004 Rodolphe Quiedeville <rodolphe@quiedeville.org>
-- Copyright (C) 2004 Laurent Destailleur <eldy@users.sourceforge.net>
--
-- $Id$
-- $Source$
--
-- 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
@@ -19,6 +16,9 @@
-- 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$
--
-- ========================================================================
create table llx_c_typent
@@ -26,5 +26,5 @@ create table llx_c_typent
id integer PRIMARY KEY,
code varchar(12) UNIQUE NOT NULL,
libelle varchar(30),
active tinyint default 1 NOT NULL
active tinyint DEFAULT 1 NOT NULL
)type=innodb;

View File

@@ -26,7 +26,7 @@ create table llx_commande
tms timestamp,
fk_soc integer,
fk_soc_contact integer,
fk_projet integer default 0, -- projet auquel est rattache la commande
fk_projet integer DEFAULT 0, -- projet auquel est rattache la commande
ref varchar(30) NOT NULL, -- propal number
date_creation datetime, -- date de creation
date_valid datetime, -- date de validation

View File

@@ -26,10 +26,10 @@ create table llx_commandedet
fk_product integer,
label varchar(255),
description text,
tva_tx real default 19.6, -- taux tva
qty real, -- quantit<69>
remise_percent real default 0, -- pourcentage de remise
remise real default 0, -- montant de la remise
tva_tx real DEFAULT 19.6, -- taux tva
qty real, -- quantit<69>
remise_percent real DEFAULT 0, -- pourcentage de remise
remise real DEFAULT 0, -- montant de la remise
subprice real, -- prix avant remise
price real -- prix final
)type=innodb;

View File

@@ -25,12 +25,12 @@ create table llx_compta
rowid integer AUTO_INCREMENT PRIMARY KEY,
datec datetime,
datev date, -- date de valeur
amount real NOT NULL default 0,
amount real DEFAULT 0 NOT NULL ,
label varchar(255),
fk_compta_account integer,
fk_user_author integer,
fk_user_valid integer,
valid tinyint default 0,
valid tinyint DEFAULT 0,
note text
)type=innodb;

View File

@@ -24,7 +24,7 @@ create table llx_cond_reglement
(
rowid integer PRIMARY KEY,
sortorder smallint,
actif tinyint default 1,
actif tinyint DEFAULT 1,
libelle varchar(255),
libelle_facture text,
fdm tinyint, -- reglement fin de mois

View File

@@ -25,7 +25,7 @@ create table llx_contrat
(
rowid integer AUTO_INCREMENT PRIMARY KEY,
tms timestamp,
enservice smallint default 0,
enservice smallint DEFAULT 0,
mise_en_service datetime,
fin_validite datetime,
date_cloture datetime,

View File

@@ -27,6 +27,6 @@ create table llx_cotisation
fk_adherent integer,
dateadh datetime,
cotisation real,
fk_bank int(11) default NULL,
fk_bank int(11) DEFAULT NULL,
note text
)type=innodb;

View File

@@ -26,7 +26,7 @@ create table llx_deplacement
datec datetime NOT NULL,
tms timestamp,
dated datetime,
fk_user integer NOT NULL,
fk_user integer NOT NULL,
fk_user_author integer,
type smallint NOT NULL,
km smallint,

View File

@@ -27,7 +27,7 @@ create table llx_don
fk_statut smallint NOT NULL DEFAULT 0,-- etat du don promesse/valid
datec datetime, -- date de cr<63>ation de l'enregistrement
datedon datetime, -- date du don/promesse
amount real default 0,
amount real DEFAULT 0,
fk_paiement integer,
prenom varchar(50),
nom varchar(50),
@@ -37,7 +37,7 @@ create table llx_don
ville varchar(50),
pays varchar(50),
email varchar(255),
public smallint NOT NULL DEFAULT 1, -- le don est-il public (0,1)
public smallint DEFAULT 1 NOT NULL, -- le don est-il public (0,1)
fk_don_projet integer NOT NULL, -- projet auquel est fait le don
fk_user_author integer NOT NULL,
fk_user_valid integer NOT NULL,

View File

@@ -25,7 +25,7 @@ create table llx_editeur
rowid integer AUTO_INCREMENT PRIMARY KEY,
oscid integer NOT NULL,
tms timestamp,
nom varchar(255),
nom varchar(255),
fk_user_author integer
)type=innodb;

View File

@@ -28,7 +28,7 @@ create table llx_entrepot
tms timestamp,
label varchar(255) NOT NULL,
description text,
statut tinyint default 1, -- 1 ouvert, 0 ferm<72>
statut tinyint DEFAULT 1, -- 1 ouvert, 0 ferm<72>
fk_user_author integer
)type=innodb;

View File

@@ -33,7 +33,7 @@ create table llx_expedition
fk_user_valid integer, -- valideur
fk_entrepot integer,
fk_expedition_methode integer,
fk_statut smallint default 0,
fk_statut smallint DEFAULT 0,
note text,
model_pdf varchar(50),

View File

@@ -27,5 +27,5 @@ create table llx_expedition_methode
code varchar(30) NOT NULL,
libelle varchar(50) NOT NULL,
description text,
statut tinyint default 0
statut tinyint DEFAULT 0
)type=innodb;

View File

@@ -22,8 +22,8 @@
create table llx_expeditiondet
(
rowid integer AUTO_INCREMENT PRIMARY KEY,
fk_expedition integer not null,
fk_commande_ligne integer not null,
fk_expedition integer NOT NULL,
fk_commande_ligne integer NOT NULL,
qty real, -- quantit<69>
key(fk_expedition),