Je voulais savoir s'il existe une manière rapide permettant de rechercher une chaine dans tous les champs d'une table (MySQL). Quelque chose du genre :
Code : Tout sélectionner
CREATE TABLE `liste_animaux` (
`ID_animal` int(6) NOT NULL auto_increment,
`nom` varchar(255) NOT NULL default '',
`contenu` text NOT NULL,
`date` date NOT NULL default '0000-00-00',
PRIMARY KEY (`ID_animal`)
) ENGINE=MyISAM AUTO_INCREMENT=13 DEFAULT CHARSET=latin1 AUTO_INCREMENT=13 ;
SELECT animaux FROM liste_animaux WHERE *='%lap%'