How to quickly remove all goods and orders from the opencart store
How to remove quickly all goods from the store - instruction
Creation, development, manufacturing sites | WEB-STYDIA.COM

Today one of my clients addressed me for help. And the help was as follows, he needed to remove all the goods and orders from the online store. Since he sold his ready-made online store, and the new owner needed the store clean without goods and orders.

The first thing that probably comes to you is the problem? Why not remove all products from the admin panel by selecting the desired items and clicking the delete button, and do the same thing from the orders.

And I agree with this completely with you, remove all the goods from the Opencart store by this method the right decision, but what if you do not have 500 products in the store and for example 20-30 thousand, you imagine how much time it takes to remove all these goods and orders from the admin panel, this you need half a day to sit and squeeze the button to remove.

Therefore, we will go the other way and remove all the goods and orders from the store in a few minutes, I would even say a few seconds, all we need to do is clear the necessary tables in the database.

And so, in order to quickly remove all the goods in opencart go to your database that is connected to your store via phpmyadmin, (if you do not know what database you need to enter, open the configuration file config.php, which is located in your website root and peep at the name of your database), and in the list of tables, find the following tables:

Mark them and select the clear item at the very bottom. (The prefix of the tables oc_ you may have to consider this differently).



Well, or the second option is more correct and faster, it will also delete all link URLs specifically tied to the goods, you can simply execute the SQL query:

That's all, now your store does not have a single product.

Our next task will be to clear all orders in opencart, that is, zero order numbers, so that subsequent order numbers start from the first, well, there were no old orders in the store.

We will do exactly the same as with the cleaning of the goods, we still go to the database and mark all the tables that begin with oc_order And just choose the bottom at the bottom of the page. This way you can delete all orders from the opencart store.

PS: Forgot to specify: You do not need to clear the oc_order_status table, there are order status titles in it, if you clear it, then all Order statuses must be registered manually again.

You can also simply execute a SQL query to quickly clear orders:

Well, that's all, you will agree that it is faster and easier than sitting for hours and deleting goods and orders from the administrative panel of the store. You can also go through FTP to your site in the image folder /image/data/ and delete the folders with photos that you do not need anymore.



Finally, if you want, you can also delete users and all customers from the opencart store, for this, execute the following query or manually clean the tables from the list below:

In such a simple way and having spent just a couple of minutes, we completely cleaned our online store of old orders and the entire product base.

Good luck to you.

You may also like

No Comment

You can post first response comment.

Leave A Comment

Please enter your name. Please enter an valid email address. Please enter a message.