Answer the question
In order to leave comments, you need to log in
Wordpress search not looking for quoted text?
Hi all!
WordPress search does not search for text with quotes like:
set "Felika" in the search is not present
if removed, finds this text with quotes
set Felik
finds the product
Answer the question
In order to leave comments, you need to log in
Because it's not Google, the search looks for exact occurrences of words. If you make a typo, it won't find anything either. You can look towards elastic search or the ElasticPress plugin
It will be correct instead of type (0,1) to simply make the sum signed, positive - income, negative - expense. And then it will be:
SELECT `login`, SUM(IF(`sum` > 0, `sum`, 0)) AS `in`,
SUM(IF(`sum` < 0, `sum`, 0)) AS `out`, SUM(`sum`) AS `total`
FROM `info_user`
GROUP BY `login`
SELECT
LOGIN,
SUM(IF(TYPE=0, SUM, 0)) OUT_COME,
SUM(IF(TYPE=1, SUM, 0)) IN_COME,
FROM
INFO_USER
GROUP BY
LOGIN
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question