Bonjour,
Pour préciser nos souci par rapport à la recherche fulltext et à la clé primais dans le plugin ZotSpip...
On a un souci avec zotspip. La clé primaire de la table principale
n'est pas numérique. Pour y remédier, j'ai rajoutée une clé primaire
numérique et ignoré la première :
$zitems = array(
'id_zotspip' => 'bigint(21) NOT NULL UNIQUE AUTO_INCREMENT', //
Ajout GL
"id_zitem" => "varchar(16) DEFAULT '' NOT NULL",
"id_parent" => "varchar(16) DEFAULT '' NOT NULL",
"type_ref" => "varchar(255) DEFAULT '' NOT NULL",
"annee" => "smallint(6)",
"titre" => "text DEFAULT '' NOT NULL",
"auteurs" => "text DEFAULT '' NOT NULL",
"resume" => "mediumtext DEFAULT '' NOT NULL",
"date" => "varchar(255) DEFAULT '' NOT NULL",
"pages" => "varchar(255) DEFAULT '' NOT NULL",
"publication" => "text DEFAULT '' NOT NULL",
"editeur" => "text DEFAULT '' NOT NULL",
"collection" => "varchar(255) DEFAULT '' NOT NULL",
"conference" => "text DEFAULT '' NOT NULL",
"type_doc" => "text DEFAULT '' NOT NULL",
"volume" => "varchar(255) DEFAULT '' NOT NULL",
"numero" => "varchar(255) DEFAULT '' NOT NULL",
"doi" => "varchar(255) DEFAULT '' NOT NULL",
"isbn" => "varchar(255) DEFAULT '' NOT NULL",
"issn" => "varchar(255) DEFAULT '' NOT NULL",
"url" => "text DEFAULT '' NOT NULL",
"extras" => "text DEFAULT '' NOT NULL",
"mimetype" => "varchar(255) DEFAULT '' NOT NULL",
"poids" => "bigint",
"fichier" => "text DEFAULT '' NOT NULL",
"json" => "mediumtext DEFAULT '' NOT NULL",
"csljson" => "mediumtext DEFAULT '' NOT NULL",
"updated" => "varchar(50) DEFAULT '' NOT NULL",
"date_ajout" => "varchar(50) DEFAULT '' NOT NULL",
);
$zitems_cles = array(
"PRIMARY KEY" => "id_zotspip",
"KEY id_parent" => "id_parent",
);
Du coup, ça marche pour les recherche, ( enfin pas tout à fait pour la
fulltext... ), mais les jointure ne se font plus.
Pour info, il y a ça dans le fichier pour déclarer les jointures :
//-- Jointures ----------------------------------------------------
$interface['tables_jointures']['spip_zitems'][] = 'ztags';
$interface['tables_jointures']['spip_zitems'][] = 'zcreators';
$interface['tables_jointures']['spip_zitems'][] =
'zitems_zcollections';
$interface['tables_jointures']['spip_zcollections'][] =
'zitems_zcollections';
$interface['tables_jointures']['spip_ztags'][] = 'zitems';
$interface['tables_jointures']['spip_zcreators'][] = 'zitems';
Faudrait-il les modifier aussi ?
Merci d'avance de vos réponses, ça fait plusieurs jours que j'essaie de
faire marcher les jointure et la recherche en même temps et je n'y
arrive pas. Je commence à être désespéré...
--
Gilles Lengy
Artaban Communication
33 (0)1 40 09 18 18
www.artaban.fr
spip.artaban.fr
Adhérent de l'April (www.april.org)
---
L'absence de virus dans ce courrier électronique a été vérifiée par le logiciel antivirus Avast.
https://www.avast.com/antivirus