Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Problem with page parse time


Mfred

Recommended Posts

Hi,

 

we have here a huge problem on the index.php site and the page parse them of this site.

 

25/01/2007 13:02:58 - /shop/index.php (4.545s)

 

Also we have a testinstallation with a 1:1 copy of the liveshop and there the parsetimes are ok:

 

25/01/2007 13:02:21 - /testshop/index.php (0.933s)

 

 

 

Interesting also that it only appears on the index.php site. All other pages load quite fast.

 

Any hints on this problem?

 

br,

mfred

Link to comment
Share on other sites

25/01/2007 13:02:58 - /shop/index.php (4.545s)

25/01/2007 13:02:21 - /testshop/index.php (0.933s)

Interesting also that it only appears on the index.php site.

Maybe .htaccess in home directory? Really 1:1 copy?

Link to comment
Share on other sites

In the meantime I found out its due to the featured products contribution

 

the main sql query is taking 2.5 - 2.9 seconds:

 

SELECT p.products_id, p.products_image, p.products_tax_class_id, s.status AS specstat, s.specials_new_products_price, p.products_price

FROM products p

LEFT JOIN specials s ON p.products_id = s.products_id

LEFT JOIN featured f ON p.products_id = f.products_id

WHERE p.products_status = '1'

AND f.status = '1'

ORDER BY rand( 1699398240 ) DESC

LIMIT 12

 

The question is now how to speed up this query?

Link to comment
Share on other sites

- try add index on column products_id in table specials.

- about table featured i don't know nothing, but maybe need also index on column products_id

 

 

I tried it now in a test environment and indexing really speeds up the thing.

 

The only point I didnt already do it in production environment is a Warning I get in phpmyadmin:

 

"Die Index-Typen INDEX und PRIMARY sollten nicht gleichzeitig für die Spalte `products_id` gesetzt sein"

 

like: The Index Types INDEX and PRIMARY should not be set at the same time for columt products_id

 

 

Can I ignore it or worry about ?

 

thx

mfred

Link to comment
Share on other sites

You have 2 tables - specials,featured. First table was without index. If Y trieing add index on indexed column in second table... i don't know nothing about second table. Your informations are deficiently for me. But probably now all is OK, if speed is good. ;)

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...