diff --git a/mysql/Makefile b/mysql/Makefile index 48cce3631a8..9aa796e5401 100644 --- a/mysql/Makefile +++ b/mysql/Makefile @@ -1,4 +1,3 @@ -# # Copyright (C) 2001-2003 Rodolphe Quiedeville # Copyright (C) 2005 Laurent Destailleur # @@ -25,10 +24,6 @@ # accessible à http://localhost/dolibarr/install/ # # Pour une installation manuelle, créer la base dolibarr puis faire: -# make table -# make load -# -# Ou bien, toujours après avoir créer la base dolibarr: # make mysql.sql # mysql dolibarr < mysql.sql # @@ -51,18 +46,6 @@ TABLES=$(shell $(FIND) tables/ -name "*sql") all: cat README - -show: - cd tables \ - && make show BASE=$(BASE) OPTIONS=$(OPTIONS) - -drop: - $(SQL) $(OPTIONS) $(BASE) < drop.sql - -table: - cd tables \ - && make create BASE=$(BASE) OPTIONS=$(OPTIONS) - load: $(SQL) $(OPTIONS) $(BASE) < data/data.sql @@ -72,10 +55,6 @@ dev: - -fulldev: drop table load dev - - dropall: dropdb droppriv droppriv: @@ -86,7 +65,7 @@ dropdb: -create: drop createdb createpriv +create: createdb createpriv createdb: $(SQL) $(OPTIONS) mysql -e "create database $(BASE) ; " diff --git a/mysql/README b/mysql/README index 6189c621810..303b5cd0cb1 100644 --- a/mysql/README +++ b/mysql/README @@ -1,19 +1,8 @@ # Makefile Options ##################### -- show Affiche la liste des tables - - -- drop Supprime toutes les tables et clés de la base - -- table Crée les tables et clés dans la base de données - -- load Charge les données minimales définies dans data/data.sql - - -- fulldev Supprime toutes la tables, les crée à nouveau et charges les données de dev - - - mysql.sql Génère un fichier sql unique pour l'installation (Contient les ordres de création des tables + clés et index + données) +- load Charge les données minimales définies dans data/data.sql + diff --git a/mysql/convert-innodb.sql b/mysql/convert-innodb.sql deleted file mode 100644 index 082b6152e6e..00000000000 --- a/mysql/convert-innodb.sql +++ /dev/null @@ -1,194 +0,0 @@ --- --- Copyright (C) 2003 Rodolphe Quiedeville --- Copyright (C) 2004 Laurent Destailleur --- --- 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_actioncomm type=INNODB; - -alter table llx_c_chargesociales type=INNODB; - -alter table llx_c_effectif type=INNODB; - -alter table llx_c_paiement type=INNODB; - -alter table llx_c_pays type=INNODB; - -alter table llx_c_propalst type=INNODB; - -alter table llx_c_stcomm type=INNODB; - -alter table llx_c_typent type=INNODB; - -alter table llx_action_def type=INNODB; - -alter table llx_actioncomm type=INNODB; - -alter table llx_adherent type=INNODB; - -alter table llx_adherent_type type=INNODB; - -alter table llx_adherent_options type=INNODB; - -alter table llx_adherent_options_label type=INNODB; - -alter table llx_album type=INNODB; - -alter table llx_album_to_groupart type=INNODB; - -alter table llx_appro type=INNODB; - -alter table llx_auteur type=INNODB; - -alter table llx_bank type=INNODB; - -alter table llx_bank_account type=INNODB; - -alter table llx_bank_categ type=INNODB; - -alter table llx_bank_class type=INNODB; - -alter table llx_bookmark type=INNODB; - -alter table llx_boxes type=INNODB; - -alter table llx_boxes_def type=INNODB; - -alter table llx_chargesociales type=INNODB; - -alter table llx_contrat type=INNODB; - -alter table llx_compta type=INNODB; - -alter table llx_compta_account type=INNODB; - -alter table llx_concert type=INNODB; - -alter table llx_cond_reglement type=INNODB; - -alter table llx_const type=INNODB; - -alter table llx_cotisation type=INNODB; - -alter table llx_deplacement type=INNODB; - -alter table llx_domain type=INNODB; - -alter table llx_don type=INNODB; - -alter table llx_don_projet type=INNODB; - -alter table llx_editeur type=INNODB; - -alter table llx_fa_pr type=INNODB; - -alter table llx_facture type=INNODB; - -alter table llx_facture_tva_sum type=INNODB; - -alter table llx_facturedet type=INNODB; - -alter table llx_facture_fourn type=INNODB; - -alter table llx_facture_fourn_det type=INNODB; - -alter table llx_fichinter type=INNODB; - -alter table llx_groupart type=INNODB; - -alter table llx_lieu_concert type=INNODB; - -alter table llx_livre type=INNODB; - -alter table llx_livre_to_auteur type=INNODB; - -alter table llx_newsletter type=INNODB; - -alter table llx_notify type=INNODB; - -alter table llx_notify_def type=INNODB; - -alter table llx_paiement type=INNODB; - -alter table llx_paiementfourn type=INNODB; - -alter table llx_pointmort type=INNODB; - -alter table llx_product type=INNODB; - -alter table llx_product_price type=INNODB; - -alter table llx_projet type=INNODB; - -alter table llx_propal type=INNODB; - -alter table llx_propal_model_pdf type=INNODB; - -alter table llx_propaldet type=INNODB; - -alter table llx_rights_def type=INNODB; - -alter table llx_service type=INNODB; - -alter table llx_societe type=INNODB; - -alter table llx_socpeople type=INNODB; - -alter table llx_soc_events type=INNODB; - -alter table llx_socstatutlog type=INNODB; - -alter table llx_sqltables type=INNODB; - -alter table llx_todocomm type=INNODB; - -alter table llx_transaction_bplc type=INNODB; - -alter table llx_tva type=INNODB; - -alter table llx_user type=INNODB; - -alter table llx_user_rights type=INNODB; - -alter table llx_ventes type=INNODB; - -alter table llx_voyage type=INNODB; - -alter table llx_voyage_reduc type=INNODB; - -alter table llx_bank_url type=INNODB; - -alter table llx_birthday_alert type=INNODB; - -alter table llx_c_actioncomm type=INNODB; - -alter table llx_co_fa type=INNODB; - -alter table llx_entrepot type=INNODB; - -alter table llx_facture_rec type=INNODB; - -alter table llx_facturedet_rec type=INNODB; - -alter table llx_product_fournisseur type=INNODB; - -alter table llx_product_stock type=INNODB; - -alter table llx_stock_mouvement type=INNODB; - diff --git a/mysql/drop.sql b/mysql/drop.sql deleted file mode 100644 index 818001c82cf..00000000000 --- a/mysql/drop.sql +++ /dev/null @@ -1,351 +0,0 @@ --- --- Copyright (C) 2001-2005 Rodolphe Quiedeville --- --- 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$ --- --- --- L'ordre des suppressions doit respecter les contraintes d'integrite --- -drop table if exists llx_co_fa; - -drop table if exists llx_co_pr; - -drop table if exists llx_c_actioncomm; - -drop table if exists llx_c_chargesociales; - -drop table if exists llx_c_effectif; - -drop table if exists llx_c_paiement ; - -drop table if exists llx_c_prestatype ; - -drop table if exists llx_c_propalst ; - -drop table if exists llx_c_stcomm; - -drop table if exists llx_c_typent ; - -drop table if exists llx_action_def; - -drop table if exists llx_actioncomm; - -drop table if exists llx_adherent; - -drop table if exists llx_adherent_type; - -drop table if exists llx_adherent_options; - -drop table if exists llx_adherent_options_label; - -drop table if exists llx_album; - -drop table if exists llx_album_to_groupart ; - -drop table if exists llx_appro ; - -drop table if exists llx_auteur; - -drop table if exists llx_bank; - -drop table if exists llx_bank_account; - -drop table if exists llx_bank_categ; - -drop table if exists llx_bank_class; - -drop table if exists llx_bank_url; - -drop table if exists llx_birthday_alert; - -drop table if exists llx_bookmark; - -drop table if exists llx_boxes; - -drop table if exists llx_boxes_def; - -drop table if exists llx_chargesociales; - -drop table if exists llx_commande; - -drop table if exists llx_commandedet; - -drop table if exists llx_commande_fournisseur; - -drop table if exists llx_commande_fournisseur_log; - -drop table if exists llx_commande_fournisseurdet; - -drop table if exists llx_compta; - -drop table if exists llx_compta_account; - -drop table if exists llx_concert ; - -drop table if exists llx_cond_reglement ; - -drop table if exists llx_const; - -drop table if exists llx_contact_facture; - -drop table if exists llx_cotisation; - -drop table if exists llx_deplacement; - -drop table if exists llx_domain ; - -drop table if exists llx_don; - -drop table if exists llx_don_projet; - -drop table if exists llx_editeur; - -drop table if exists llx_entrepot; - -drop table if exists llx_expedition; - -drop table if exists llx_expedition_methode; - -drop table if exists llx_expeditiondet; - -drop table if exists llx_fa_pr; - -drop table if exists llx_facture_rec; - -drop table if exists llx_facturedet; - -drop table if exists llx_facturedet_rec; - -drop table if exists llx_facture_fourn; - -drop table if exists llx_facture_fourn_det; - -drop table if exists llx_fichinter; - -drop table if exists llx_groupart; - -drop table if exists llx_lieu_concert ; - -drop table if exists llx_livre; - -drop table if exists llx_livre_to_auteur ; - -drop table if exists llx_newsletter; - -drop table if exists llx_notify ; - -drop table if exists llx_notify_def; - -drop table if exists llx_paiementfourn; - -drop table if exists llx_pointmort; - -drop table if exists llx_product_fournisseur; - -drop table if exists llx_product_price; - -drop table if exists llx_product_stock; - -drop table if exists llx_propal_model_pdf; - -drop table if exists llx_propaldet; - -drop table if exists llx_rights_def; - -drop table if exists llx_service; - -drop table if exists llx_societe_ca; - -drop table if exists llx_societe_details; - -drop table if exists llx_societe_prestation; - -drop table if exists llx_societe_reference; - -drop table if exists llx_societe_remise; - -drop table if exists llx_societe_remise_except; - -drop table if exists llx_societe_rib; - -drop table if exists llx_societe_techno; - -drop table if exists llx_socpeople; - -drop table if exists llx_soc_events; - -drop table if exists llx_socstatutlog ; - -drop table if exists llx_stock; - -drop table if exists llx_stock_mouvement; - -drop table if exists llx_sqltables; - -drop table if exists llx_todocomm ; - -drop table if exists llx_transaction_bplc ; - -drop table if exists llx_tva; - -drop table if exists llx_user_rights; - -drop table if exists llx_ventes; - -drop table if exists llx_voyage; - -drop table if exists llx_voyage_reduc; - -drop table if exists llx_facture_tva_sum; - -drop table if exists llx_c_accountingsystem; - -drop table if exists llx_c_ape; - -drop table if exists llx_c_civilite; - -drop table if exists llx_c_currencies; - -drop table if exists llx_c_departements; - -drop table if exists llx_c_forme_juridique; - -drop table if exists llx_c_prestation; - -drop table if exists llx_c_regions; - -drop table if exists llx_c_techno; - -drop table if exists llx_catalog_societe; - -drop table if exists llx_catalogsoc; - -drop table if exists llx_groupesociete; -drop table if exists llx_groupesociete_remise; -drop table if exists llx_mailing; -drop table if exists llx_mailing_cibles; -drop table if exists llx_paiement_facture; -drop table if exists llx_paiementcharge; -drop table if exists llx_so_gr; - -drop table if exists llx_user_alert; -drop table if exists llx_user_param; - -drop table if exists llx_bookmark4u_login; -drop table if exists llx_c_methode_commande_fournisseur; -drop table if exists llx_compta_compte_generaux; -drop table if exists llx_contratdet; -drop table if exists llx_contratdet_log; -drop table if exists llx_export_compta; - -drop table if exists llx_prelevement_notifications; -drop table if exists llx_prelevement_facture; -drop table if exists llx_prelevement_facture_demande; -drop table if exists llx_prelevement_rejet; -drop table if exists llx_prelevement_lignes; -drop table if exists llx_prelevement_bons; -drop table if exists llx_prelevement; -drop table if exists llx_product_fournisseur_price; -drop table if exists llx_societe_commerciaux; -drop table if exists llx_user_clicktodial; -drop table if exists llx_usergroup_rights; -drop table if exists llx_usergroup_user; -drop table if exists llx_usergroup; - - -drop table if exists llx_cash; -drop table if exists llx_cash_account; -drop table if exists llx_contrat_service; -drop table if exists llx_telephonie_client_statistique; -drop table if exists llx_telephonie_client_stats; -drop table if exists llx_telephonie_client_stats_mensuel; -drop table if exists llx_telephonie_commande; -drop table if exists llx_telephonie_commande_retour; -drop table if exists llx_telephonie_communications_details; -drop table if exists llx_telephonie_concurrents; -drop table if exists llx_telephonie_contact_facture; -drop table if exists llx_telephonie_contrat; -drop table if exists llx_telephonie_contrat_contact_facture; -drop table if exists llx_telephonie_facture; -drop table if exists llx_telephonie_fournisseur; -drop table if exists llx_telephonie_groupe_ligne; -drop table if exists llx_telephonie_groupeligne; -drop table if exists llx_telephonie_import_cdr; -drop table if exists llx_telephonie_ligne_statistique; -drop table if exists llx_telephonie_prefix; -drop table if exists llx_telephonie_service; -drop table if exists llx_telephonie_simul; -drop table if exists llx_telephonie_simul_comm; -drop table if exists llx_telephonie_societe_ligne; -drop table if exists llx_telephonie_societe_ligne_remise; -drop table if exists llx_telephonie_societe_ligne_statut; -drop table if exists llx_telephonie_tarif; -drop table if exists llx_telephonie_tarif_client; -drop table if exists llx_telephonie_tarif_fournisseur; - -drop table if exists llx_categorie_association; -drop table if exists llx_categorie_product; -drop table if exists llx_product_fournisseur_price_log; -drop table if exists llx_categorie; - -drop table if exists llx_accountingsystem_det; - -drop table if exists llx_accountingsystem; - -drop table if exists llx_energie_compteur_releve; -drop table if exists llx_energie_compteur_groupe; -drop table if exists llx_energie_compteur; -drop table if exists llx_energie_groupe; -drop table if exists llx_dolibarr_modules; - -drop table if exists llx_energie_compteur_groupe; - -drop table if exists llx_energie_compteur_releve; - -drop table if exists llx_energie_groupe; - -drop table if exists llx_energie_compteur; - -drop table if exists llx_propal; - -drop table if exists llx_product; - -drop table if exists llx_facture; - -drop table if exists llx_contrat; - -drop table if exists llx_paiement; - -drop table if exists llx_c_pays ; - -drop table if exists llx_projet; - -drop table if exists llx_societe; - -drop table if exists llx_user; - --- historique - -drop table if exists c_actioncomm; -drop table if exists c_chargesociales; -drop table if exists c_effectif; -drop table if exists c_paiement; -drop table if exists c_pays; -drop table if exists c_propalst; -drop table if exists c_stcomm; -drop table if exists c_typent; diff --git a/mysql/innodb.sql b/mysql/innodb.sql deleted file mode 100644 index 6ba6f2cd409..00000000000 --- a/mysql/innodb.sql +++ /dev/null @@ -1,351 +0,0 @@ --- --- Copyright (C) 2005 Rodolphe Quiedeville --- --- 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$ --- --- --- Migration des tables au format innodb --- -alter table llx_co_fa type=INNODB; - -alter table llx_co_pr type=INNODB; - -alter table llx_c_actioncomm type=INNODB; - -alter table llx_c_chargesociales type=INNODB; - -alter table llx_c_effectif type=INNODB; - -alter table llx_c_paiement type=INNODB; - -alter table llx_c_prestatype type=INNODB; - -alter table llx_c_propalst type=INNODB; - -alter table llx_c_stcomm type=INNODB; - -alter table llx_c_typent type=INNODB; - -alter table llx_action_def type=INNODB; - -alter table llx_actioncomm type=INNODB; - -alter table llx_adherent type=INNODB; - -alter table llx_adherent_type type=INNODB; - -alter table llx_adherent_options type=INNODB; - -alter table llx_adherent_options_label type=INNODB; - -alter table llx_album type=INNODB; - -alter table llx_album_to_groupart type=INNODB; - -alter table llx_appro type=INNODB; - -alter table llx_auteur type=INNODB; - -alter table llx_bank type=INNODB; - -alter table llx_bank_account type=INNODB; - -alter table llx_bank_categ type=INNODB; - -alter table llx_bank_class type=INNODB; - -alter table llx_bank_url type=INNODB; - -alter table llx_birthday_alert type=INNODB; - -alter table llx_bookmark type=INNODB; - -alter table llx_boxes type=INNODB; - -alter table llx_boxes_def type=INNODB; - -alter table llx_chargesociales type=INNODB; - -alter table llx_commande type=INNODB; - -alter table llx_commandedet type=INNODB; - -alter table llx_commande_fournisseur type=INNODB; - -alter table llx_commande_fournisseur_log type=INNODB; - -alter table llx_commande_fournisseurdet type=INNODB; - -alter table llx_compta type=INNODB; - -alter table llx_compta_account type=INNODB; - -alter table llx_concert type=INNODB; - -alter table llx_cond_reglement type=INNODB; - -alter table llx_const type=INNODB; - -alter table llx_contact_facture type=INNODB; - -alter table llx_cotisation type=INNODB; - -alter table llx_deplacement type=INNODB; - -alter table llx_domain type=INNODB; - -alter table llx_don type=INNODB; - -alter table llx_don_projet type=INNODB; - -alter table llx_editeur type=INNODB; - -alter table llx_entrepot type=INNODB; - -alter table llx_expedition type=INNODB; - -alter table llx_expedition_methode type=INNODB; - -alter table llx_expeditiondet type=INNODB; - -alter table llx_fa_pr type=INNODB; - -alter table llx_facture_rec type=INNODB; - -alter table llx_facturedet type=INNODB; - -alter table llx_facturedet_rec type=INNODB; - -alter table llx_facture_fourn type=INNODB; - -alter table llx_facture_fourn_det type=INNODB; - -alter table llx_fichinter type=INNODB; - -alter table llx_groupart type=INNODB; - -alter table llx_lieu_concert type=INNODB; - -alter table llx_livre type=INNODB; - -alter table llx_livre_to_auteur type=INNODB; - -alter table llx_newsletter type=INNODB; - -alter table llx_notify type=INNODB; - -alter table llx_notify_def type=INNODB; - -alter table llx_paiementfourn type=INNODB; - -alter table llx_pointmort type=INNODB; - -alter table llx_product_fournisseur type=INNODB; - -alter table llx_product_price type=INNODB; - -alter table llx_product_stock type=INNODB; - -alter table llx_propal_model_pdf type=INNODB; - -alter table llx_propaldet type=INNODB; - -alter table llx_rights_def type=INNODB; - -alter table llx_service type=INNODB; - -alter table llx_societe_ca type=INNODB; - -alter table llx_societe_details type=INNODB; - -alter table llx_societe_prestation type=INNODB; - -alter table llx_societe_reference type=INNODB; - -alter table llx_societe_remise type=INNODB; - -alter table llx_societe_remise_except type=INNODB; - -alter table llx_societe_rib type=INNODB; - -alter table llx_societe_techno type=INNODB; - -alter table llx_socpeople type=INNODB; - -alter table llx_soc_events type=INNODB; - -alter table llx_socstatutlog type=INNODB; - -alter table llx_stock type=INNODB; - -alter table llx_stock_mouvement type=INNODB; - -alter table llx_sqltables type=INNODB; - -alter table llx_todocomm type=INNODB; - -alter table llx_transaction_bplc type=INNODB; - -alter table llx_tva type=INNODB; - -alter table llx_user_rights type=INNODB; - -alter table llx_ventes type=INNODB; - -alter table llx_voyage type=INNODB; - -alter table llx_voyage_reduc type=INNODB; - -alter table llx_facture_tva_sum type=INNODB; - -alter table llx_c_accountingsystem type=INNODB; - -alter table llx_c_ape type=INNODB; - -alter table llx_c_civilite type=INNODB; - -alter table llx_c_currencies type=INNODB; - -alter table llx_c_departements type=INNODB; - -alter table llx_c_forme_juridique type=INNODB; - -alter table llx_c_prestation type=INNODB; - -alter table llx_c_regions type=INNODB; - -alter table llx_c_techno type=INNODB; - -alter table llx_catalog_societe type=INNODB; - -alter table llx_catalogsoc type=INNODB; - -alter table llx_groupesociete type=INNODB; -alter table llx_groupesociete_remise type=INNODB; -alter table llx_mailing type=INNODB; -alter table llx_mailing_cibles type=INNODB; -alter table llx_paiement_facture type=INNODB; -alter table llx_paiementcharge type=INNODB; -alter table llx_so_gr type=INNODB; - -alter table llx_user_alert type=INNODB; -alter table llx_user_param type=INNODB; - -alter table llx_bookmark4u_login type=INNODB; -alter table llx_c_methode_commande_fournisseur type=INNODB; -alter table llx_compta_compte_generaux type=INNODB; -alter table llx_contratdet type=INNODB; -alter table llx_contratdet_log type=INNODB; -alter table llx_export_compta type=INNODB; - -alter table llx_prelevement_notifications type=INNODB; -alter table llx_prelevement_facture type=INNODB; -alter table llx_prelevement_facture_demande type=INNODB; -alter table llx_prelevement_rejet type=INNODB; -alter table llx_prelevement_lignes type=INNODB; -alter table llx_prelevement_bons type=INNODB; -alter table llx_prelevement type=INNODB; -alter table llx_product_fournisseur_price type=INNODB; -alter table llx_societe_commerciaux type=INNODB; -alter table llx_user_clicktodial type=INNODB; -alter table llx_usergroup_rights type=INNODB; -alter table llx_usergroup_user type=INNODB; -alter table llx_usergroup type=INNODB; - - -alter table llx_cash type=INNODB; -alter table llx_cash_account type=INNODB; -alter table llx_contrat_service type=INNODB; -alter table llx_telephonie_client_statistique type=INNODB; -alter table llx_telephonie_client_stats type=INNODB; -alter table llx_telephonie_client_stats_mensuel type=INNODB; -alter table llx_telephonie_commande type=INNODB; -alter table llx_telephonie_commande_retour type=INNODB; -alter table llx_telephonie_communications_details type=INNODB; -alter table llx_telephonie_concurrents type=INNODB; -alter table llx_telephonie_contact_facture type=INNODB; -alter table llx_telephonie_contrat type=INNODB; -alter table llx_telephonie_contrat_contact_facture type=INNODB; -alter table llx_telephonie_facture type=INNODB; -alter table llx_telephonie_fournisseur type=INNODB; -alter table llx_telephonie_groupe_ligne type=INNODB; -alter table llx_telephonie_groupeligne type=INNODB; -alter table llx_telephonie_import_cdr type=INNODB; -alter table llx_telephonie_ligne_statistique type=INNODB; -alter table llx_telephonie_prefix type=INNODB; -alter table llx_telephonie_service type=INNODB; -alter table llx_telephonie_simul type=INNODB; -alter table llx_telephonie_simul_comm type=INNODB; -alter table llx_telephonie_societe_ligne type=INNODB; -alter table llx_telephonie_societe_ligne_remise type=INNODB; -alter table llx_telephonie_societe_ligne_statut type=INNODB; -alter table llx_telephonie_tarif type=INNODB; -alter table llx_telephonie_tarif_client type=INNODB; -alter table llx_telephonie_tarif_fournisseur type=INNODB; - -alter table llx_categorie_association type=INNODB; -alter table llx_categorie_product type=INNODB; -alter table llx_product_fournisseur_price_log type=INNODB; -alter table llx_categorie type=INNODB; - -alter table llx_accountingsystem_det type=INNODB; - -alter table llx_accountingsystem type=INNODB; - -alter table llx_energie_compteur_releve type=INNODB; -alter table llx_energie_compteur_groupe type=INNODB; -alter table llx_energie_compteur type=INNODB; -alter table llx_energie_groupe type=INNODB; -alter table llx_dolibarr_modules type=INNODB; - -alter table llx_energie_compteur_groupe type=INNODB; - -alter table llx_energie_compteur_releve type=INNODB; - -alter table llx_energie_groupe type=INNODB; - -alter table llx_energie_compteur type=INNODB; - -alter table llx_propal type=INNODB; - -alter table llx_product type=INNODB; - -alter table llx_facture type=INNODB; - -alter table llx_contrat type=INNODB; - -alter table llx_paiement type=INNODB; - -alter table llx_c_pays type=INNODB; - -alter table llx_projet type=INNODB; - -alter table llx_societe type=INNODB; - -alter table llx_user type=INNODB; - --- historique - -alter table c_actioncomm type=INNODB; -alter table c_chargesociales type=INNODB; -alter table c_effectif type=INNODB; -alter table c_paiement type=INNODB; -alter table c_pays type=INNODB; -alter table c_propalst type=INNODB; -alter table c_stcomm type=INNODB; -alter table c_typent type=INNODB; diff --git a/mysql/tables/llx_pointmort.sql b/mysql/tables/llx_pointmort.sql deleted file mode 100644 index ee9ca0506af..00000000000 --- a/mysql/tables/llx_pointmort.sql +++ /dev/null @@ -1,27 +0,0 @@ --- =================================================================== --- Copyright (C) 2001-2002 Rodolphe Quiedeville --- --- 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$ --- =================================================================== - -create table llx_pointmort -( - month datetime, - amount real -)type=innodb; - diff --git a/pgsql/Makefile b/pgsql/Makefile index 528fafd8f84..18f507145fe 100644 --- a/pgsql/Makefile +++ b/pgsql/Makefile @@ -1,4 +1,3 @@ -# # Copyright (C) 2001-2002 Rodolphe Quiedeville # Copyright (C) 2002-2003 Éric Seigne # Copyright (C) 2004 Benoit Mortier @@ -26,14 +25,10 @@ # accessible à http://localhost/dolibarr/install/ # # Pour une installation manuelle, créer la base dolibarr puis faire: -# make table -# make load +# make pgsql.sql +# mysql dolibarr < pgsql.sql # -# Ou bien, toujours après avoir créer la base dolibarr: -# make mysql.sql -# mysql dolibarr < mysql.sql -# -# Le script mysql.sql cotient tous le ordres sql pour créer la base +# Le script pgsql.sql cotient tous le ordres sql pour créer la base # Tables + Index et Clés + Données # # ********************************************************************** @@ -43,8 +38,8 @@ BASE=dolibarr OPTIONS=-U postgres OWNER=dolibarradm OWNERPASS=azaz -#FIND=find -FIND="c:/Program files/cygwin/bin/find" +FIND=find +#FIND="c:/Program files/cygwin/bin/find" TABLES=$(shell $(FIND) tables/ -name "*sql") @@ -53,16 +48,6 @@ TABLES=$(shell $(FIND) tables/ -name "*sql") all: cat README -show: - cd tables \ - && make show - -drop: - $(SQL) $(OPTIONS) $(BASE) < drop.sql - -table: - cd tables \ - && make create load: $(SQL) $(OPTIONS) $(BASE) < data/data.sql @@ -72,9 +57,6 @@ dev: -fulldev: drop table load dev - - drop: droppriv dropdb dropuser droppriv: @@ -88,7 +70,7 @@ dropdb: -create: drop createuser createdb createpriv +create: createuser createdb createpriv createuser: $(SQL) $(OPTIONS) template1 -c "create user $(OWNER) with UNENCRYPTED PASSWORD '$(OWNERPASS)' ; " diff --git a/pgsql/README b/pgsql/README index 8f89f918c0a..f4140bd210a 100644 --- a/pgsql/README +++ b/pgsql/README @@ -1,19 +1,7 @@ # Makefile Options ##################### -- show Affiche la liste des tables - - -- drop Supprime toutes les tables et clés de la base - -- table Crée les tables et clés dans la base de données - -- load Charge les données minimales définies dans data/data.sql - - -- fulldev Supprime toutes la tables, les crée à nouveau et charges les données de dev - - - pgsql.sql Génère un fichier sql unique pour l'installation (Contient les ordres de création des tables + clés et index + données) +- load Charge les données minimales définies dans data/data.sql diff --git a/pgsql/drop-constraints.sql b/pgsql/drop-constraints.sql deleted file mode 100644 index 31c51f581d2..00000000000 --- a/pgsql/drop-constraints.sql +++ /dev/null @@ -1,43 +0,0 @@ --- ============================================================================ --- Copyright (C) 2004 Benoit Mortier --- --- 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. --- --- Ce fichier sert a effacer les contraintes sur les tables de la database --- --- $Id$ --- $Source$ --- --- ============================================================================ - -ALTER TABLE llx_fichinter DROP CONSTRAINT "fichinter_fk_soc_idp"; - -ALTER TABLE llx_propal DROP CONSTRAINT "propal_fk_soc_idp"; - -ALTER TABLE llx_facture DROP CONSTRAINT "facture_fk_soc_idp"; - -ALTER TABLE llx_facturedet DROP CONSTRAINT "facturedet_fk_facture_rowid"; - -ALTER TABLE llx_facture_tva_sum DROP CONSTRAINT "facture_tva_sum_fk_facture_rowid"; - -ALTER TABLE llx_socpeople DROP CONSTRAINT "socpeople_fk_soc_idp"; - -ALTER TABLE llx_paiement_facture DROP CONSTRAINT "paiement_facture_fk_facture"; - -ALTER TABLE llx_paiement_facture DROP CONSTRAINT "paiement_facture_fk_paiement"; - -ALTER TABLE llx_c_departements DROP CONSTRAINT "c_departements_fk_region"; - -ALTER TABLE llx_c_regions DROP CONSTRAINT "c_regions_fk_pays"; diff --git a/pgsql/drop.sql b/pgsql/drop.sql deleted file mode 100644 index 728323450c3..00000000000 --- a/pgsql/drop.sql +++ /dev/null @@ -1,208 +0,0 @@ --- --- Copyright (C) 2001-2002 Rodolphe Quiedeville --- Copyright (C) 2002-2003 Eric Seigne --- Copyright (C) 2004 Benoit Mortier --- --- 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$ --- - -drop table llx_co_fa; - -drop table llx_co_pr; - -drop table llx_c_actioncomm; - -drop table llx_c_chargesociales; - -drop table llx_c_effectif; - -drop table llx_c_paiement ; - -drop table llx_c_pays ; - -drop table llx_c_prestatype ; - -drop table llx_c_propalst ; - -drop table llx_c_stcomm; - -drop table llx_c_typent ; - -drop table llx_action_def; - -drop table llx_actioncomm; - -drop table llx_adherent; - -drop table llx_adherent_type; - -drop table llx_adherent_options; - -drop table llx_adherent_options_label; - -drop table llx_album; - -drop table llx_album_to_groupart ; - -drop table llx_appro ; - -drop table llx_auteur; - -drop table llx_bank; - -drop table llx_bank_account; - -drop table llx_bank_categ; - -drop table llx_bank_class; - -drop table llx_bank_url; - -drop table llx_birthday_alert; - -drop table llx_bookmark; - -drop table llx_boxes; - -drop table llx_boxes_def; - -drop table llx_chargesociales; - -drop table llx_contrat; - -drop table llx_commande; - -drop table llx_commandedet; - -drop table llx_compta; - -drop table llx_compta_account; - -drop table llx_concert ; - -drop table llx_cond_reglement ; - -drop table llx_const; - -drop table llx_cotisation; - -drop table llx_deplacement; - -drop table llx_domain ; - -drop table llx_don; - -drop table llx_don_projet; - -drop table llx_editeur; - -drop table llx_entrepot; - -drop table llx_expedition; - -drop table llx_expedition_methode; - -drop table llx_expeditiondet; - -drop table llx_fa_pr; - -drop table llx_facture; - -drop table llx_facture_rec; - -drop table llx_facturedet; - -drop table llx_facturedet_rec; - -drop table llx_facture_fourn; - -drop table llx_facture_fourn_det; - -drop table llx_fichinter; - -drop table llx_groupart; - -drop table llx_lieu_concert ; - -drop table llx_livre; - -drop table llx_livre_to_auteur ; - -drop table llx_newsletter; - -drop table llx_notify ; - -drop table llx_notify_def; - -drop table llx_paiement; - -drop table llx_paiementfourn; - -drop table llx_pointmort; - -drop table llx_product; - -drop table llx_product_fournisseur; - -drop table llx_product_price; - -drop table llx_product_stock; - -drop table llx_projet; - -drop table llx_propal; - -drop table llx_propal_model_pdf; - -drop table llx_propaldet; - -drop table llx_rights_def; - -drop table llx_service; - -drop table llx_societe; - -drop table llx_socpeople; - -drop table llx_soc_events; - -drop table llx_socstatutlog ; - -drop table llx_stock; - -drop table llx_stock_mouvement; - -drop table llx_sqltables; - -drop table llx_todocomm ; - -drop table llx_transaction_bplc ; - -drop table llx_tva; - -drop table llx_user; - -drop table llx_user_rights; - -drop table llx_ventes; - -drop table llx_voyage; - -drop table llx_voyage_reduc; - -drop table llx_facture_tva_sum; diff --git a/pgsql/tables/llx_pointmort.sql b/pgsql/tables/llx_pointmort.sql deleted file mode 100644 index a925b6a78fb..00000000000 --- a/pgsql/tables/llx_pointmort.sql +++ /dev/null @@ -1,31 +0,0 @@ --- Generated from dolibarr_mysql2pgsql --- (c) 2004, PostgreSQL Inc. --- (c) 2005, Laurent Destailleur. - --- =================================================================== --- Copyright (C) 2001-2002 Rodolphe Quiedeville --- --- 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$ --- =================================================================== - -create table llx_pointmort -( - "month" timestamp, - "amount" real -); -