1
It has as I make a search of the last name of a people but with regular expression?
Today I use the SUBSTRING_INDEX
to catch the last name, the more I want to take parts of this last name, when I search by name or name fragments of people I am using the REGEXP calling a function of mine that creates a regular expression.
When I try to use the SUBSTRING_INDEX
with the REGEXP
stop not very sure not.
Using cakephp to develop.
The command line below:
$filtros = array_merge($filtros, array("SUBSTRING_INDEX(Usuario.nome, ' ', 1) = 'REGEXP \"".$this->stringParaBusca($criterios["criteriaPrimeiroNome"])."\"'"));
I was able to solve, I just took the "=" really, thank you.
– Jeremias Pereira
@Jeremiaspereira accept the answer of our colleague then...
– Igor Martins