<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title><![CDATA[FrontAccounting forum — Search function in 2.4.2]]></title>
		<link>https://frontaccounting.com/punbb/viewtopic.php?id=6932</link>
		<atom:link href="https://frontaccounting.com/punbb/extern.php?action=feed&amp;tid=6932&amp;type=rss" rel="self" type="application/rss+xml" />
		<description><![CDATA[The most recent posts in Search function in 2.4.2.]]></description>
		<lastBuildDate>Mon, 21 Aug 2017 07:51:38 +0000</lastBuildDate>
		<generator>PunBB</generator>
		<item>
			<title><![CDATA[Re: Search function in 2.4.2]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=28462#p28462</link>
			<description><![CDATA[<p>Hi - I will test it at the end of the week.</p>]]></description>
			<author><![CDATA[null@example.com (spott)]]></author>
			<pubDate>Mon, 21 Aug 2017 07:51:38 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=28462#p28462</guid>
		</item>
		<item>
			<title><![CDATA[Re: Search function in 2.4.2]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=28457#p28457</link>
			<description><![CDATA[<p>It appears that your session vale for the collation is specifically <strong>utf8mb4_unicode_ci</strong> which is different from the others.</p><p>You can test it in a local XAMPP first and see if the issue persists.</p><p>I have no issue with the standard <strong>en_US-demo.sql</strong> on XAMPP. You too can try the standard en_US demo CoA as a plain vanilla install (not an upgrade) and see if the issue persists. If it goes away, then compare your db schemas to see what gives.</p><p>If all else fails, PM me a link to your DB backup sans pwds/txns and the specific build of FA you are using and I will test it out in a sandbox. That way we can check if it is a php script issue or a MySQL db issue.</p><p>State the versions of PHP, MySQL, Apache, OS platform.</p>]]></description>
			<author><![CDATA[null@example.com (apmuthu)]]></author>
			<pubDate>Mon, 21 Aug 2017 03:06:48 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=28457#p28457</guid>
		</item>
		<item>
			<title><![CDATA[Re: Search function in 2.4.2]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=28453#p28453</link>
			<description><![CDATA[<p>Nothing - I cleared cache, even tried incognito with browser.<br />Variables - I don&#039;t have ssh access to server, but phpMyAdmin shows that:<br /><a href="https://www.upload.ee/image/7368594/database.png">[img]https://www.upload.ee/thumb/7368594/database.png[/img]</a></p>]]></description>
			<author><![CDATA[null@example.com (spott)]]></author>
			<pubDate>Sun, 20 Aug 2017 13:47:05 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=28453#p28453</guid>
		</item>
		<item>
			<title><![CDATA[Re: Search function in 2.4.2]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=28452#p28452</link>
			<description><![CDATA[<p>Check the output of:<br /></p><div class="codebox"><pre><code>SHOW VARIABLES LIKE &quot;%collation%&quot;;</code></pre></div><p>Clear the company/#/js_cache/*/*.js files, logout, clear browser cache and login again after closing all browser instances.</p>]]></description>
			<author><![CDATA[null@example.com (apmuthu)]]></author>
			<pubDate>Sun, 20 Aug 2017 12:11:00 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=28452#p28452</guid>
		</item>
		<item>
			<title><![CDATA[Re: Search function in 2.4.2]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=28450#p28450</link>
			<description><![CDATA[<p>Hi<br />I added this line to includes/db/connect_db_mysqli.inc - it looks now so:<br />$db = mysqli_connect($connection[&quot;host&quot;], $connection[&quot;dbuser&quot;], $connection[&quot;dbpassword&quot;], &quot;&quot;, <br />&nbsp; &nbsp; &nbsp; &nbsp; !empty($connection[&quot;port&quot;]) ? $connection[&quot;port&quot;] : 3306); // default port in mysql is 3306<br />&nbsp; &nbsp; &nbsp; &nbsp; <br />&nbsp; &nbsp; mysqli_select_db($db, $connection[&quot;dbname&quot;]);<br />&nbsp; &nbsp; ///// From mysqli release 5.6.6 the sql_mode is no longer empty as it was prior to<br />&nbsp; &nbsp; ///// this release. Just for safety we make it empty for all 5.6 release and higher.<br />&nbsp; &nbsp; ///// This non empty sql_mode values can interphere with FA, so all is set empty during<br />&nbsp; &nbsp; ///// our sessions.<br />&nbsp; &nbsp; ///// We are, however, investigating the existing code to be compatible in the future.<br />&nbsp; &nbsp; db_query(&quot;SET sql_mode = &#039;&quot;.SQL_MODE.&quot;&#039;&quot;);<br />&nbsp; &nbsp; /////added fix<br />&nbsp; &nbsp; db_query(&quot;SET @@collation_connection = @@collation_database&quot;);<br />&nbsp; &nbsp; /////<br />&nbsp; &nbsp; $SysPrefs-&gt;refresh();<br />&nbsp; &nbsp; return $db;</p><p>But it doesn&#039;t help. Or I need something to change in customers_db.inc file also?<br />Collation - in config_db.php and also in database - all tables are utf8_unicode_ci</p>]]></description>
			<author><![CDATA[null@example.com (spott)]]></author>
			<pubDate>Sun, 20 Aug 2017 12:00:48 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=28450#p28450</guid>
		</item>
		<item>
			<title><![CDATA[Re: Search function in 2.4.2]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=28449#p28449</link>
			<description><![CDATA[<p>If we want the &quot;LIKE&quot; parameter to be <strong>case-insensitive</strong> then the <a href="https://stackoverflow.com/questions/18853452/sql-select-like-insensitive-casing">database collation should be <strong>utf8_general_ci</strong></a>. Otherwise if the db and connection collations are different, we will need to set the comparables in the LIKE statement to be &quot;LOWER(field1) LIKE CONCAT(&quot;%&quot;,@cmpstr,&quot;%&quot;)&quot; in places like <strong>function get_customers_search()</strong> in <strong>sales/includes/db/customers_db.inc</strong> or cast / convert the collations on a per sql basis.</p><p>The real workaround:</p><p>After the last <em>db_query()</em> in the <strong>function set_global_connection()</strong> in <strong>includes/db/connect_db_mysqli.inc</strong>, add the following:<br /></p><div class="codebox"><pre><code>    db_query(&quot;SET @@collation_connection = @@collation_database&quot;);</code></pre></div><p>The above will help avoid &quot;Illegal mix of collations&quot; error by synching the connection collation to that of the database and make for case-insensitive searching. It will also benefit those in a single db environment on a shared hosting platform with possibly different collations for each application - YMMV.</p><p>It is possible that the collation of the customer name may have been of a different collation as well - check your CoA and db schema!</p><p>@joe: can we commit this - after all the db collation should dictate such usage.</p>]]></description>
			<author><![CDATA[null@example.com (apmuthu)]]></author>
			<pubDate>Sun, 20 Aug 2017 11:11:19 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=28449#p28449</guid>
		</item>
		<item>
			<title><![CDATA[Search function in 2.4.2]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=28445#p28445</link>
			<description><![CDATA[<p>Hi<br />I today upgraded from 2.3.26 to 2.4.2. And one thing, what I discovered - customer search is broken - ok - its not broken, but it has lost one very important thing - Most of my customers and suppliers names beginning with uppercase letter - some of them are all uppercase in name. In 2.3 version - in search - there was no problem with search - I can write in lowercase beginning of the name and it finds it. Example - Netikink - for searching I need to write only - neti and thats fine. Now in 2.4 search doesn&#039;t search any more uppercase/lowercase letters together. So when I am searching now neti - it gives me nothing. I need to write Neti - and then it finds it.</p><p>Is it possible to fix it?</p><p>EDIT: Item search and supplier search working as needed - there is no problem with uppercase/lowecase. So the problem is only in customer part - when searching customers.</p>]]></description>
			<author><![CDATA[null@example.com (spott)]]></author>
			<pubDate>Sun, 20 Aug 2017 07:54:56 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=28445#p28445</guid>
		</item>
	</channel>
</rss>
