- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-25-2019
03:57 AM
09-25-2019
03:57 AM
Hello,
I have the following table in my magento database sitting at 350mb called:
customer_visitor
What is the SQL command to delete all the visits before September 2019? I don't want to truncate the whole table.
Solved! Go to Solution.
Labels:
1 ACCEPTED SOLUTION
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-25-2019
04:56 AM
09-25-2019
04:56 AM
Hi @callam_kidsaw,
You can delete from table using following query.
To get the result to verify. SELECT * FROM FROM customer_visitor WHERE last_visit_at < '2019-09-01'; then you can delete if data is correct.
DELETE FROM customer_visitor WHERE last_visit_at < '2019-09-01';
I hope it will help you!
1 REPLY 1
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-25-2019
04:56 AM
09-25-2019
04:56 AM
Hi @callam_kidsaw,
You can delete from table using following query.
To get the result to verify. SELECT * FROM FROM customer_visitor WHERE last_visit_at < '2019-09-01'; then you can delete if data is correct.
DELETE FROM customer_visitor WHERE last_visit_at < '2019-09-01';
I hope it will help you!