From 9cc0956cd51fb7610cf0beda029a9d866a317f05 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Fri, 18 Feb 2011 17:01:28 +0000 Subject: [PATCH] Fix: Export was missing records --- htdocs/includes/modules/modSociete.class.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/htdocs/includes/modules/modSociete.class.php b/htdocs/includes/modules/modSociete.class.php index 9c8c80650b9..af936dae374 100644 --- a/htdocs/includes/modules/modSociete.class.php +++ b/htdocs/includes/modules/modSociete.class.php @@ -228,10 +228,10 @@ class modSociete extends DolibarrModules unset($this->export_entities_array[$r]['s.code_fournisseur']); } $this->export_sql_start[$r]='SELECT DISTINCT '; - $this->export_sql_end[$r] =' FROM '.MAIN_DB_PREFIX.'c_pays as p, '.MAIN_DB_PREFIX.'socpeople as c'; + $this->export_sql_end[$r] =' FROM '.MAIN_DB_PREFIX.'socpeople as c'; $this->export_sql_end[$r] .=' LEFT JOIN '.MAIN_DB_PREFIX.'societe as s ON c.fk_soc = s.rowid'; - $this->export_sql_end[$r] .=' WHERE c.fk_pays = p.rowid'; - $this->export_sql_end[$r] .=' AND c.entity = '.$conf->entity; + $this->export_sql_end[$r] .=' LEFT JOIN '.MAIN_DB_PREFIX.'c_pays as p ON c.fk_pays = p.rowid'; + $this->export_sql_end[$r] .=' WHERE c.entity = '.$conf->entity; // Imports