Created
May 24, 2018 16:59
-
-
Save ip413/551b6aa7bb0cd9215dda67a0539d260d to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Deleting all customer messages in prestashop written in Russian | |
-- Search for three most popular russian characters "о, е, а" | |
-- Deleting thread info from ps_customer_thread column | |
delete from | |
ps_customer_thread | |
where | |
id_customer_thread in ( | |
select | |
id_customer_thread | |
from | |
ps_customer_message | |
where | |
( | |
ps_customer_message.message like "%о%" | |
OR ps_customer_message.message like "%е%" | |
OR ps_customer_message.message like "%а%" | |
) | |
) | |
-- Deleting messages from ps_customer_message column | |
delete from | |
ps_customer_message | |
where | |
( | |
ps_customer_message.message like "%о%" | |
OR ps_customer_message.message like "%е%" | |
OR ps_customer_message.message like "%а%" | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment