Exporting Products from Magento – making it quicker

The phrase take only what you need springs to mind when it comes to exporting products in Magento. The lack of a check all button to ignore all field options in the export can lead to a waste of time if you only want 2 or 3 specific columns. Enter developer tools in (some/most modern browsers) Chrome and a little bit of Javascript magic.

Entering this in the console tab in the developer tools (right click and choose inspect from the menu that appears)  and all the checkboxes are checked and you can spend your time selecting which columns it is you need.

Code comes from here

Deleting Duplicate Records using MySQL

I recently had a table which ended up with some duplicate records being imported. A simple way to achieve this is to use a subquery as follows:

If you want to keep the row with the lowest id value:

If you want the id value that is the highest:

Original Article: Stack Overflow

Use Developer tools to select DB tables quickly.

If like me you find yourself emptying the same tables again and again (test orders etc) it can be frustrating to check 20-30 tables. Why not let the developer tools in Chrome do it for you.
For example the javascript below will select all the sales data tables you will need to empty if you want to reset all the order tables. Just open the inspector and paste the Javascript into the console.

To customise this to suit your requirements simply replace the value=”; with your database table names.