1578 0 0 2
Last Updated : 2024-03-29 05:07:35
There is how to search for a complete tag word in a comma separated values field in DB table.
$query->where('tags', 'RLIKE', "^[[:<:]]{$tag}[[:>:]],")->orwhere('tags', 'RLIKE', "^[[:<:]]{$tag}[[:>:]]$")->orwhere('tags', 'RLIKE', ",[[:<:]]{$tag}[[:>:]],")->orwhere('tags', 'RLIKE', ",[[:<:]]{$tag}[[:>:]]$");
Mohammed Anwar
Wow, That's truly nice snippet of code :)
Mohammed Anwar
Thank from here again :)