| home | resources | search | news | join | members: 6963 |
Hiveminds | Wed, 2007-09-05 08:10 tags: Developer Zone, Drupal The locale module looks for the translations for text. The problem is that the SQL is using an inner join so the process is taking 77 ms. It is not cached all the time so it presents a heavy bottleneck on a busy website. What we did was change the INNER JOIN to a LEFT JOIN and adjusted the functions code a bit. This is on line 195 of the locale module. After the above changes the query time was reduced to 13ms.
SELECT s.lid, t.translation FROM locales_source s INNER JOIN locales_target t ON s.lid = t.lid AND t.locale = 'sv' WHERE s.source = '
<?php
SELECT s.lid, t.translation FROM locales_source s INNER JOIN locales_target t ON s.lid = t.lid AND t.locale = 'sv' WHERE s.source = '
This article brought to you by the
Hiveminds Magazine - Staff. Contact us if you want to post an article or announcement anonymously |
Windows London Hotels
Adobe Flex Content Management Systems Laptop Reviews
Wordpress Just Dial International Calls
Adobe Flex Silverlight Excel Training Courses
Wordpress excel courses in london
eRuby Data Recovery
|
NewsletterGet updates on Hiveminds services, articles and downloads by signing up for the newsletter. |
Editor's choiceSome of the better articles, stories and tutorials found at Hiveminds. |
Find moreFind more of Hiveminds articles, stories, tutorials and user comments by searching. |
Picked linksHand picked websites and articles from around the web that provide quality reading. |