From fcac51436c8de547ca9e179b6231789fe2fe82d1 Mon Sep 17 00:00:00 2001 From: Michael RICOIS Date: Fri, 25 Nov 2011 16:37:44 +0000 Subject: [PATCH] Confusion dans la configuration --- config/Sphinx/Dev/dir.conf | 31 +++++++++--------- config/Sphinx/Dev/dirtmp.conf | 37 ++++++++++++++++++++++ config/SphinxHisto/MysqlServer/dir.conf | 36 --------------------- config/SphinxHisto/MysqlServer/dirtmp.conf | 37 ++++++++++++++++++++++ config/srvws02/srvws02/dir.conf | 29 +++++++++-------- 5 files changed, 105 insertions(+), 65 deletions(-) create mode 100644 config/Sphinx/Dev/dirtmp.conf delete mode 100644 config/SphinxHisto/MysqlServer/dir.conf create mode 100644 config/SphinxHisto/MysqlServer/dirtmp.conf diff --git a/config/Sphinx/Dev/dir.conf b/config/Sphinx/Dev/dir.conf index 609fb58..188a76d 100644 --- a/config/Sphinx/Dev/dir.conf +++ b/config/Sphinx/Dev/dir.conf @@ -7,25 +7,26 @@ source dir sql_db = jo sql_query_pre = sql_query = - SELECT id, siren, actif, \ - IF(civilite='M',1,IF(civilite='MME' OR civilite='MLLE',2,0)) AS genre, \ - CONCAT(nom,' ',naissance_nom, ' ', dirRS) AS nom, prenom, \ - YEAR(naissance_date) AS naiss_annee, \ - MONTH(naissance_date) AS naiss_mois, \ - DAY(naissance_date) AS naiss_jour, \ - naissance_lieu, adr_dep \ - FROM rncs_dirigeants; - sql_attr_uint = naiss_annee - sql_attr_uint = naiss_mois - sql_attr_uint = naiss_jour - sql_attr_uint = actif - sql_attr_uint = genre - sql_attr_uint = adr_dep + SELECT id, siren, adr_dep, typeDir, dirSiren, civilite, CONCAT(nom,' ',naissance_nom, ' ', dirRS) AS nom, prenom, \ + YEAR(naissance_date) AS naiss_annee, \ + MONTH(naissance_date) AS naiss_mois, \ + DAY(naissance_date) AS naiss_jour, \ + naissance_lieu, fonction_code, actif \ + FROM dirigeants; + sql_attr_str2ordinal = civilite + sql_attr_str2ordinal = typeDir + sql_attr_str2ordinal = fonction_code + sql_attr_uint = dirSiren + sql_attr_uint = naiss_annee + sql_attr_uint = naiss_mois + sql_attr_uint = naiss_jour + sql_attr_uint = actif + sql_attr_uint = adr_dep } index dir { - source = source_dir + source = dir path = /dbs/sphinx/dir docinfo = extern morphology = none diff --git a/config/Sphinx/Dev/dirtmp.conf b/config/Sphinx/Dev/dirtmp.conf new file mode 100644 index 0000000..e26bd34 --- /dev/null +++ b/config/Sphinx/Dev/dirtmp.conf @@ -0,0 +1,37 @@ +source dir +{ + type = mysql + sql_host = 192.168.78.230 + sql_user = sphinx + sql_pass = indexer + sql_db = jo + sql_query_pre = + sql_query = + SELECT id, siren, adr_dep, typeDir, dirSiren, civilite, CONCAT(nom,' ',naissance_nom, ' ', dirRS) AS nom, prenom, \ + YEAR(naissance_date) AS naiss_annee, \ + MONTH(naissance_date) AS naiss_mois, \ + DAY(naissance_date) AS naiss_jour, \ + naissance_lieu, fonction_code, actif \ + FROM dirigeants_tmp; + sql_attr_str2ordinal = civilite + sql_attr_str2ordinal = typeDir + sql_attr_str2ordinal = fonction_code + sql_attr_uint = dirSiren + sql_attr_uint = naiss_annee + sql_attr_uint = naiss_mois + sql_attr_uint = naiss_jour + sql_attr_uint = actif + sql_attr_uint = adr_dep +} + +index dir +{ + source = dir + path = /dbs/sphinx/dir + docinfo = extern + morphology = none + charset_type = sbcs + charset_table = 0..9, A..Z->a..z, a..z, \ + U+23, U+25, U+26, U+2B, U+3D, U+40, \ + U+C0..U+DE->U+E0..U+FE, U+DF, U+E0..U+FF +} diff --git a/config/SphinxHisto/MysqlServer/dir.conf b/config/SphinxHisto/MysqlServer/dir.conf deleted file mode 100644 index 0f74f94..0000000 --- a/config/SphinxHisto/MysqlServer/dir.conf +++ /dev/null @@ -1,36 +0,0 @@ -source dir -{ - type = mysql - sql_host = 192.168.3.30 - sql_user = sphinx - sql_pass = indexer - sql_db = jo - sql_query_pre = - sql_query = - SELECT id, siren, actif, \ - IF(civilite='M',1,IF(civilite='MME' OR civilite='MLLE',2,0)) AS genre, \ - CONCAT(nom,' ',naissance_nom, ' ', dirRS) AS nom, prenom, \ - YEAR(naissance_date) AS naiss_annee, \ - MONTH(naissance_date) AS naiss_mois, \ - DAY(naissance_date) AS naiss_jour, \ - naissance_lieu, adr_dep \ - FROM rncs_dirigeants; - sql_attr_uint = naiss_annee - sql_attr_uint = naiss_mois - sql_attr_uint = naiss_jour - sql_attr_uint = actif - sql_attr_uint = genre - sql_attr_uint = adr_dep -} - -index dir -{ - source = source_dir - path = /dbs/sphinx/dir - docinfo = extern - morphology = none - charset_type = sbcs - charset_table = 0..9, A..Z->a..z, a..z, \ - U+23, U+25, U+26, U+2B, U+3D, U+40, \ - U+C0..U+DE->U+E0..U+FE, U+DF, U+E0..U+FF -} diff --git a/config/SphinxHisto/MysqlServer/dirtmp.conf b/config/SphinxHisto/MysqlServer/dirtmp.conf new file mode 100644 index 0000000..62472cb --- /dev/null +++ b/config/SphinxHisto/MysqlServer/dirtmp.conf @@ -0,0 +1,37 @@ +source dir +{ + type = mysql + sql_host = 192.168.3.30 + sql_user = sphinx + sql_pass = indexer + sql_db = jo + sql_query_pre = + sql_query = + SELECT id, siren, adr_dep, typeDir, dirSiren, civilite, CONCAT(nom,' ',naissance_nom, ' ', dirRS) AS nom, prenom, \ + YEAR(naissance_date) AS naiss_annee, \ + MONTH(naissance_date) AS naiss_mois, \ + DAY(naissance_date) AS naiss_jour, \ + naissance_lieu, fonction_code, actif \ + FROM dirigeants_tmp; + sql_attr_str2ordinal = civilite + sql_attr_str2ordinal = typeDir + sql_attr_str2ordinal = fonction_code + sql_attr_uint = dirSiren + sql_attr_uint = naiss_annee + sql_attr_uint = naiss_mois + sql_attr_uint = naiss_jour + sql_attr_uint = actif + sql_attr_uint = adr_dep +} + +index dir +{ + source = source_dir + path = /dbs/sphinx/dir + docinfo = extern + morphology = none + charset_type = sbcs + charset_table = 0..9, A..Z->a..z, a..z, \ + U+23, U+25, U+26, U+2B, U+3D, U+40, \ + U+C0..U+DE->U+E0..U+FE, U+DF, U+E0..U+FF +} diff --git a/config/srvws02/srvws02/dir.conf b/config/srvws02/srvws02/dir.conf index 0f74f94..197d68c 100644 --- a/config/srvws02/srvws02/dir.conf +++ b/config/srvws02/srvws02/dir.conf @@ -7,20 +7,21 @@ source dir sql_db = jo sql_query_pre = sql_query = - SELECT id, siren, actif, \ - IF(civilite='M',1,IF(civilite='MME' OR civilite='MLLE',2,0)) AS genre, \ - CONCAT(nom,' ',naissance_nom, ' ', dirRS) AS nom, prenom, \ - YEAR(naissance_date) AS naiss_annee, \ - MONTH(naissance_date) AS naiss_mois, \ - DAY(naissance_date) AS naiss_jour, \ - naissance_lieu, adr_dep \ - FROM rncs_dirigeants; - sql_attr_uint = naiss_annee - sql_attr_uint = naiss_mois - sql_attr_uint = naiss_jour - sql_attr_uint = actif - sql_attr_uint = genre - sql_attr_uint = adr_dep + SELECT id, siren, adr_dep, typeDir, dirSiren, civilite, CONCAT(nom,' ',naissance_nom, ' ', dirRS) AS nom, prenom, \ + YEAR(naissance_date) AS naiss_annee, \ + MONTH(naissance_date) AS naiss_mois, \ + DAY(naissance_date) AS naiss_jour, \ + naissance_lieu, fonction_code, actif \ + FROM dirigeants; + sql_attr_str2ordinal = civilite + sql_attr_str2ordinal = typeDir + sql_attr_str2ordinal = fonction_code + sql_attr_uint = dirSiren + sql_attr_uint = naiss_annee + sql_attr_uint = naiss_mois + sql_attr_uint = naiss_jour + sql_attr_uint = actif + sql_attr_uint = adr_dep } index dir