Code Sharing Repository Public source code sharing repository http://devcodepro.com Full text search order by relevance - Code Sharing Repository SELECT SQL_CALC_FOUND_ROWS *, MATCH (title,description) AGAINST ('Text') as score FROM posts WHERE MATCH (title,description) AGAINST ('Text') ORDER by score DESC; http://devcodepro.com/view/60/1/Full-text-search-order-by-relevance http://devcodepro.com/view/60/1/Full-text-search-order-by-relevance Wed, 13 Dec 2017 05:18:51 GMT Search MySQL utf8 and latin1 - Code Sharing Repository SELECT * FROM tablename WHERE MATCH (name,description) AGAINST ('phrase' IN BOOLEAN MODE) or convert(cast(convert(name using latin1) as binary) using utf8) = 'phrase' or convert(cast(convert(description using latin1) as binary) using utf8) = 'phrase'; SELECT *... http://devcodepro.com/view/57/1/Search-MySQL-utf8-and-latin1 http://devcodepro.com/view/57/1/Search-MySQL-utf8-and-latin1 Thu, 16 Nov 2017 19:47:54 GMT select *, COUNT left join MySQL - Code Sharing Repository SELECT *, COUNT(reviewid) AS counter FROM article LEFT JOIN reviews on article.id = reviews.articleid GROUP BY article.id, reviews.articleid ORDER BY article.id DESC LIMIT 12; http://devcodepro.com/view/48/12/select-COUNT-left-join-MySQL http://devcodepro.com/view/48/12/select-COUNT-left-join-MySQL Sun, 6 Aug 2017 17:14:06 GMT MySQL update - Incorrect date value: 0000-00-00 00:00:00 - Code Sharing Repository UPDATE `users` SET `lastdate`='2017-01-01 00:00:00'; ALTER TABLE `users` CHANGE `lastdate` `lastdate` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP; http://devcodepro.com/view/47/12/MySQL-update-Incorrect-date-value-0000-00-00-00-00-00 http://devcodepro.com/view/47/12/MySQL-update-Incorrect-date-value-0000-00-00-00-00-00 Sun, 6 Aug 2017 05:31:35 GMT Select one table count(*) from multiple tables MySQL - Code Sharing Repository SELECT *, (SELECT COUNT(postid) FROM posts where user = 4) AS counter, (SELECT COUNT(revid) FROM reviews where userid = 4) AS counters FROM users where usid = 4 LIMIT 1 http://devcodepro.com/view/45/1/Select-one-table-count-from-multiple-tables-MySQL http://devcodepro.com/view/45/1/Select-one-table-count-from-multiple-tables-MySQL Wed, 2 Aug 2017 17:43:46 GMT