Category: SQL

SQL: Remove HTML with procidure

I had a problem with client’s data that was saved as HTML in the database and I needed it in plain format. Many would say this is very inefficient way of doing it but sometimes desperate time call for desperate

It's only fair to share...Buffer this pageShare on FacebookTweet about this on TwitterShare on Google+Share on LinkedInShare on RedditPin on PinterestEmail this to someone
Posted in Small Tips, SQL Tagged with: , ,

Magento: How to reset admin pssword

If you forget your admin password for Magento and you can’t remember the email or just want quick fix you can use one line of SQL to sort that issue out. [cc lang=”sql”]UPDATE admin_user SET password=CONCAT(MD5(‘qXpassword’), ‘:qX’) WHERE username=’admin’;[/cc] All

It's only fair to share...Buffer this pageShare on FacebookTweet about this on TwitterShare on Google+Share on LinkedInShare on RedditPin on PinterestEmail this to someone
Posted in Magento, Small Tips, SQL Tagged with: , ,

MySQL – Delete/Drop all tables with specific prefix

MySQL is great database especially for small and mid size web applications. You can do loads of stuff with it but not everything is possible with regular SQL query. Imagine you have a database and you want to delete set

It's only fair to share...Buffer this pageShare on FacebookTweet about this on TwitterShare on Google+Share on LinkedInShare on RedditPin on PinterestEmail this to someone
Posted in Small Tips, SQL Tagged with: , , ,