Category Archives: Work

Access MySQL server over SSH tunnel using Navicat

Today was my first time to access a MySQL server over a SSH tunnel in Navicat. After a bit of trial and error I was finally able to achieve success ๐Ÿ™‚ Here are the main things I learned: #1 On the client machine running Navicat, use the same credentials that you would use if you were at the console of the remote server. In this case localhost and port 3306 #2 On the SSH tab, use the remote server’s IP

Replace () / . characters in phone numbers with dashes (MySQL database)

If you have a MySQL database containing phone number records in varying formats, you may want to standardize them. New records can easily be handled by checking data entry against your desired format (via JS or whatever method you like). However, existing records must be dealt with. That is where an UPDATE statement combined some handy MySQL functions can assist us: // Replace forward slash with dash UPDATE db_phonenumbers SET phone_field = REPLACE(phone_field, ‘/’, ‘-‘) // Replace close parenthesis with

Acer Aspire M5 583P wifi driver fix

Q. Here us a wifi driver question from a reader comment: hello, coming to u again for some help, this time im upgrading athe hdd to an ssd on an Acer Aspire M5 583p-9688. here is a rundown on what ive attempted. cloned original hdd to ssd using paragon software ( was successful when i cloned the hdd for the asus laptop). physically swapped the drives. f12 settings changed UFEI boot settings to Legacy, placed SSD on top of the

GoDaddy 2014 Renewal Coupon Code for .COMs

Recently I needed to renew about ten domains names at GoDaddy and it took me forever to find a promo code that worked for RENEWALS. Finally I found one for discounted renewals: GDBBX1705 *copy and paste the code into the coupon section at the bottom of the GoDaddy checkout page You can apply the coupon code here: GoDaddy Renewal Discount It saved me $48.54 so that’s not too shabby ๐Ÿ™‚

Data truncated for column ‘status’ at row 1 [SOLVED]

Recently I encountered the following error: Data truncated for column ‘status’ at row 1 This was specifically in aย PHP based web hotel/reservations app that uses MySQL for the database backend. When trying to add a new dropdown option value of ‘departed’, the form submission would always fail with the aforementioned error. Thankfully, the solution was easy once I checked the table/field definitions. The column ‘status’ was of type enum and thus needed to have the ‘departed’ value specifically enumerated in

Enable remote MySQL access (root non-local access)

Often one of the first tasks after setting up a MySQL server is to enable connections from other IP addresses. Here are a some articles that discuss how to setup a user that can access a MySQL database remotely (non-locally). Between the two of them you will have all the info you need to create user accounts for remote MySQL db access ๐Ÿ™‚ If you are in a testing environment you can also enable non-local root access for all databases

Regenerate thumbnails error on WordPress [SOLVED]

Recently I switched to a new WordPress theme and subsequently encountered some image thumbnail issues. Here is the specific error I received when regenerating thumbnails: function (){if(l){var t=l.length;(function i(t){x.each(t,function(t,n){var r=x.type(n);”function”===r?e.unique&&p.has(n)||l.push(n):n&&n.length&&”string”!==r&&i(n)})})(arguments),n?o=l.length:r&&(s=t,c(r))}return this} This was particularly frustrating, because if a custom size is not available then WordPress will use the FULL size image even for thumbnails. This of course results in slow page times and wasted bandwidth ๐Ÿ™ The solution Thankfully, after a little checking it appeared to be a simple permissions