Skip to content

Instantly share code, notes, and snippets.

@micronax
Last active August 29, 2015 14:22
Show Gist options
  • Save micronax/26d6395795c42caa937a to your computer and use it in GitHub Desktop.
Save micronax/26d6395795c42caa937a to your computer and use it in GitHub Desktop.
Alle Shopware-Produkte aus der Datenbank entfernen. Dabei bleiben Kategorien, Configurator-Sets, Konfiguration usw. unangetastet.
SET FOREIGN_KEY_CHECKS = 0;
TRUNCATE TABLE `s_articles`;
TRUNCATE TABLE `s_articles_attributes`;
TRUNCATE TABLE `s_articles_categories`;
TRUNCATE TABLE `s_articles_categories_ro`;
TRUNCATE TABLE `s_articles_details`;
TRUNCATE TABLE `s_articles_img`;
TRUNCATE TABLE `s_articles_prices`;
TRUNCATE TABLE `s_articles_similar_shown_ro`;
TRUNCATE TABLE `s_articles_top_seller_ro`;
TRUNCATE TABLE `s_emarketing_lastarticles`;
TRUNCATE TABLE `s_filter_articles`;
TRUNCATE TABLE s_article_configurator_sets;
TRUNCATE TABLE s_article_configurator_options;
TRUNCATE TABLE s_articles_also_bought_ro;
TRUNCATE TABLE s_article_configurator_set_group_relations;
TRUNCATE TABLE s_article_configurator_set_option_relations;
TRUNCATE TABLE s_core_rewrite_urls;
DELETE FROM `s_media` WHERE `albumID` = -1;
TRUNCATE TABLE s_article_configurator_option_relations;
SET FOREIGN_KEY_CHECKS = 1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment