{"action":"created","issue":{"url":"https://api.github.com/repos/joomla/joomla-cms/issues/17361","repository_url":"https://api.github.com/repos/joomla/joomla-cms","labels_url":"https://api.github.com/repos/joomla/joomla-cms/issues/17361/labels{/name}","comments_url":"https://api.github.com/repos/joomla/joomla-cms/issues/17361/comments","events_url":"https://api.github.com/repos/joomla/joomla-cms/issues/17361/events","html_url":"https://github.com/joomla/joomla-cms/issues/17361","id":246762249,"number":17361,"title":"Search results ordering are not according to best match","user":{"login":"hakanara","id":16389546,"avatar_url":"https://avatars1.githubusercontent.com/u/16389546?v=4","gravatar_id":"","url":"https://api.github.com/users/hakanara","html_url":"https://github.com/hakanara","followers_url":"https://api.github.com/users/hakanara/followers","following_url":"https://api.github.com/users/hakanara/following{/other_user}","gists_url":"https://api.github.com/users/hakanara/gists{/gist_id}","starred_url":"https://api.github.com/users/hakanara/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hakanara/subscriptions","organizations_url":"https://api.github.com/users/hakanara/orgs","repos_url":"https://api.github.com/users/hakanara/repos","events_url":"https://api.github.com/users/hakanara/events{/privacy}","received_events_url":"https://api.github.com/users/hakanara/received_events","type":"User","site_admin":false},"labels":[{"id":138443932,"url":"https://api.github.com/repos/joomla/joomla-cms/labels/No%20Code%20Attached%20Yet","name":"No Code Attached Yet","color":"ededed","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":7,"created_at":"2017-07-31T13:50:42Z","updated_at":"2017-08-01T14:59:06Z","closed_at":null,"body":"In other words, is the search string is found in the title of an article, I expect it to be displayed above the other results, (above the matches in the content).\r\nThis issue is separated from #11996\r\n\r\n### Steps to reproduce the issue\r\nActivate the search content plugin and search a word that is found in one of the titles of an article.\r\n\r\n### Expected result\r\nIf the word in the title matches, that should be displayed above the other results where the match is within the content. (this is generally what we are used to see from Google search results.)\r\n\r\n### Actual result\r\nArticles are ordered according to the article id but not according to the matching titles first and then the matching content.\r\n\r\n### Additional comments\r\nMaybe SQL and Joomla gurus find a way to merge two search queries. The first searches in the titles, second searches in the content. The first query results are displayed first and then the second query results come. \r\n\r\nI have also set up a fresh Joomla installation with test data (Teaching Joomla in English). After setting it up, I have searched the Word Joomla in the search box.\r\n\r\nHere is the order of the search results:\r\n\r\n    Templates\r\n    Protostar\r\n    Plugins\r\n    Park Blog\r\n    Navigation Modules\r\n    Modules\r\n    Languages\r\n    Joomla!\r\n    Extensions\r\n\r\nAs you see the article with Joomla is not ranking 1st but 8th.\r\nI am talking about \"search content plugin\" which is available on this test site by default."},"comment":{"url":"https://api.github.com/repos/joomla/joomla-cms/issues/comments/319396482","html_url":"https://github.com/joomla/joomla-cms/issues/17361#issuecomment-319396482","issue_url":"https://api.github.com/repos/joomla/joomla-cms/issues/17361","id":319396482,"user":{"login":"mbabker","id":368545,"avatar_url":"https://avatars2.githubusercontent.com/u/368545?v=4","gravatar_id":"","url":"https://api.github.com/users/mbabker","html_url":"https://github.com/mbabker","followers_url":"https://api.github.com/users/mbabker/followers","following_url":"https://api.github.com/users/mbabker/following{/other_user}","gists_url":"https://api.github.com/users/mbabker/gists{/gist_id}","starred_url":"https://api.github.com/users/mbabker/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mbabker/subscriptions","organizations_url":"https://api.github.com/users/mbabker/orgs","repos_url":"https://api.github.com/users/mbabker/repos","events_url":"https://api.github.com/users/mbabker/events{/privacy}","received_events_url":"https://api.github.com/users/mbabker/received_events","type":"User","site_admin":false},"created_at":"2017-08-01T14:59:06Z","updated_at":"2017-08-01T14:59:06Z","body":"> I prefer to use this search since smart search stores massive data in the database.\r\n\r\nThat's kind of how search platforms work though.  They store an index of the data on your site in a specialized set of tables (or whatever the platform uses for storage) and query that when you issue a search.\r\n\r\n`com_search` plugins are really just a simple \"query this table, see if these fields contain search term\", they don't have the logic to be able to do weighted searches or order results in a way that would be most logical for the user."}}
{"actor":{"display_login":"mbabker"}}