Jump to content

Guest ID's - do they need to be deleted to speed up site?


bnadauld

Recommended Posts

Im unsure about how PS deals with Guest ID's. I assume that when a prospective customer looks at my shop, Prestashop issues them a Guest ID. I was thinking that i get a lot of hits - and each time Prestahsop records this visit. When the next/new person/customer goes to my shop does it take ages for the database to go through the whole database to find the next blank row to add this Guest ID data for the new person? Could this be slowing down my site (its on a shared server - so it gonna be slower). If i was to somehow delete all this 'old' data would it speed up the site (in particular the 'proceed to check out' step) - Its taking ages to get to the checkout and leading to loads of abandoned carts (see my other post its related ).

 

Hope someone knows something?

Link to comment
Share on other sites

On 7/5/2020 at 4:37 AM, solsol69 said:

have you had any luck with it? Ive emptied out a few tables already which speeds things up normally:

 

ps_guests
ps_connections
ps_connections_source

But this proceed to cart issue is driving all my customer away. It painfully slow to get to the cart

 

Edited by bnadauld (see edit history)
Link to comment
Share on other sites

  • 2 years later...

Best to use this query for clearing out the guest database

This will keep the info for converted guests / carts, and just erase the guests that did not convert to customers (which will be most of them)

DELETE g FROM pr_guest as g
LEFT JOIN pr_cart as c ON g.id_guest = c.id_guest
WHERE c.id_cart IS NULL
AND
g.id_customer = 0

Link to comment
Share on other sites

Below SQL query help me to speed up the website and reduce the size of database ( I have maximum 3 GB limit from web hosting account)

 

TRUNCATE TABLE ps_connections;
TRUNCATE TABLE ps_connections_source;
TRUNCATE TABLE ps_connections_page;
TRUNCATE TABLE ps_guest;
TRUNCATE TABLE ps_log;
TRUNCATE TABLE ps_referrer;
TRUNCATE TABLE ps_referrer_shop;
TRUNCATE TABLE ps_referrer_cache;
TRUNCATE TABLE ps_pagenotfound;
TRUNCATE TABLE ps_mail;
TRUNCATE TABLE ps_statssearch;
TRUNCATE TABLE ps_smarty_cache;
TRUNCATE TABLE ps_smarty_last_flush;
TRUNCATE TABLE ps_smarty_lazy_cache;

Edited by Zohaib-fk
Post Updated (see edit history)
Link to comment
Share on other sites

  • 2 weeks later...
On 7/31/2022 at 2:52 AM, Zohaib-fk said:

Below SQL query help me to speed up the website and reduce the size of database ( I have maximum 3 GB limit from web hosting account)

 

TRUNCATE TABLE ps_connections;
TRUNCATE TABLE ps_connections_source;
TRUNCATE TABLE ps_connections_page;
TRUNCATE TABLE ps_guest;
TRUNCATE TABLE ps_log;
TRUNCATE TABLE ps_referrer;
TRUNCATE TABLE ps_referrer_shop;
TRUNCATE TABLE ps_referrer_cache;
TRUNCATE TABLE ps_pagenotfound;
TRUNCATE TABLE ps_mail;
TRUNCATE TABLE ps_statssearch;
TRUNCATE TABLE ps_smarty_cache;
TRUNCATE TABLE ps_smarty_last_flush;
TRUNCATE TABLE ps_smarty_lazy_cache;

you sure truncating all these table wont break things?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...