Created
April 3, 2021 07:01
-
-
Save sudhanshu-bajaj/a12c601f9f4cb280c153fa38f14d80c7 to your computer and use it in GitHub Desktop.
Magento 2: How to delete all customers data?
This file contains 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
SET FOREIGN_KEY_CHECKS = 0; | |
TRUNCATE TABLE `amazon_customer`; | |
TRUNCATE TABLE `customer_address_entity`; | |
TRUNCATE TABLE `customer_address_entity_datetime`; | |
TRUNCATE TABLE `customer_address_entity_decimal`; | |
TRUNCATE TABLE `customer_address_entity_int`; | |
TRUNCATE TABLE `customer_address_entity_text`; | |
TRUNCATE TABLE `customer_address_entity_varchar`; | |
TRUNCATE TABLE `customer_entity`; | |
TRUNCATE TABLE `customer_entity_datetime`; | |
TRUNCATE TABLE `customer_entity_decimal`; | |
TRUNCATE TABLE `customer_entity_int`; | |
TRUNCATE TABLE `customer_entity_text`; | |
TRUNCATE TABLE `customer_entity_varchar`; | |
TRUNCATE TABLE `customer_grid_flat`; | |
TRUNCATE TABLE `customer_log`; | |
TRUNCATE TABLE `customer_visitor`; | |
TRUNCATE TABLE `persistent_session`; | |
TRUNCATE TABLE `login_as_customer`; | |
TRUNCATE TABLE `magento_login_as_customer_log`; | |
TRUNCATE TABLE `wishlist`; | |
TRUNCATE TABLE `wishlist_item`; | |
TRUNCATE TABLE `wishlist_item_option`; | |
TRUNCATE TABLE `salesrule_customer`; | |
SET FOREIGN_KEY_CHECKS = 1; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment