Finding Your Warnings in the MySQL Command Line

As I’ve mentioned before, I use the command line mysql client to edit data on our server (just say no to phpMyAdmin on production servers!). The other day I updated a table and got the following message:

Rows matched: 1  Changed: 1  Warnings: 1

What the hell! Why is there a warning!

To figure it out you can run the following command and it will tell you. The only downside is that you must run it as the next command on your connection.


How to Provide a Free Trial


When you put a site out one of the key metrics that you’re going to want to track is how often you convert a visitor to a customer. One of the great ways to do this is to provide a free trial of your service for anyone who wants it. What you don’t want to do is create so much friction that people abandon the process and cause a potential customer to try a competitor.

Limit the Questions

You want to limit the number and the complexity of your questions. It should include nothing that isn’t absolutely required to start the site. Does your marketing department want demographic information? You can request it after they’ve become a customer and throw in a discount for filling out all the information. I’ve tried several sites where they ask how many employees my company has and there have been times were I haven’t know.

An amazing example of just asking for the minimum amount of information is FreshBooks. Their trial form consists of two elements. TWO. When I signed up for their service a couple years ago I think it asked for a password but it looks like they removed that requirement too.

Don’t Ask for a Credit Card

Two reasons for this item.

First, if you’re going to provide a free trial don’t be a dick about it and have something about how you’ll not bill them if they cancel before the 30 day trial is up. This is just a convent way for you to get some income. What you really want to do is have such a great product that they’re going to want to give you money at the end of the thirty days so they can keep using it. Then you can present them with a message that says, hey I hope you’re enjoying your time here and if you are you really need to help us pay for it. Then if they don’t pay up you don’t need to worry about it. Just move on.

Secondly, it’s yet another barrier to getting that user to try your product. They might have to get approval, ask for a company credit card, and then fill out that information. This actually happened to me, I wanted to try a piece of software and the signup form required a valid credit card. In order to do this it would have been a three step process of getting my manager’s approval, her asking our assistant to signup for the site and then getting all the information filled out. On top of that I then need to ask my manager if I can have a credit card number for something that I haven’t even TRIED yet.

Instant Setup

The site should be setup for your potential customer as soon as they’re done filling out your minimal form. Again, this is from personal experience. I wanted to sign up for a service so I clicked on their “Free Trial” button and was presented with a form asking for my email address and name. Okay, not a horrible process. I filled out the form only to be presented with a message letting me know that someone would contact me to setup the site. That person then contacted me 3 days later and asked for a bunch of information that could have easily been asked for on the original form. After responding a full 2 days later I had my free trial. I didn’t haven’t been back.

Free Tier

If at all possible, provide a free tier. Mandrill is a service I use regularly because I can easily setup a new client (again with just a few required fields) with their service and if they hit the more than 12,000 email (which, let’s be honest, is a lot of emails and most of my clients won’t hit that) it’s simple to add credits to the account.

One screen for a free trial

I’m sure you’ve run into this before. You click “free trial”, then you have to choose what level of service you want to have the free trial at (Low Grade, Mid Grade, or Platinum). This is just another choice that will scare potential customers away. Just give them the highest level of service so they can see all the features and how they work. Then once they’ve seen the feature that will save them money they’ll be more than happy to shell out an extra couple bucks for it.

Demo Data

Load up their site with Demo data for common tasks. That way they can see what happens with actual data. Have a tasks feature in your site? Add some examples of what they might want do to in your app so it can be a learning experience.


It’s important to treat potential customers just like your current customers and provide a nice clean interface to get them into your system. By reducing any barrier to them trying your software you’re increasing the chance that they will give you money.

Link Post: Lessons From A Lifetime Of Being A Programmer

This one is my favorite:

Customers only know what they want after they see it.

But these are good too:

The entire software industry is built on top of wild ass guesses.

Quality is best measured at the customer.

My job is to lie to customers, your job is to make me look good.

The last one is a quote from a sales person. This is always a bad relationship to have with your sales people and is usually an indication that you’re in a toxic work environment.

Paste And Indent in Sublime Text

Sublime Text 2 is my preferred text editor at the moment because of all the cool features it has and it’s speed. One of the things that bothers me is it doesn’t match the level of indentation when you copy and paste some code:

See all those extra tabs at the beginning of the line? It’s a travesty…

What if there was a better way? Sublime Text has a feature that does this automatically. It’s called “Paste and Indent”. It has a nice shortcut but it’s kind of a paint to use because you have to retrain your brain to use Ctrl+Shift+V instead of the normal Ctrl+V for a single app.

To fix this minor problem you can change the key bindings. On a PC there is a menu option Preferences > Key Bindings – User and on the Mac it’s Sublime Text > Preferences > Key Bindings – User.

In the file that this opens up you’re going to change it to the following (unless you already have something in there and then you should add the two middle lines):

    { "keys": ["ctrl+v"], "command": "paste_and_indent" },
    { "keys": ["ctrl+shift+v"], "command": "paste" }

Now when you paste something into sublime it will automatically match the indent level.

It’s a minor annoyance but it saves me time every day.

Loading Bootstrap Tooltip’s Data Dynamically Using AJAX

For one of my client projects I’ve been using Bootstrap and it provides a tooltip option so you can hover over something and have a little extra piece of information included:

This is easy to do but what if the process to get this information adds a significant amount of processing time? You can dynamically load the data from another URL. The first step is to setup the element:

<div class="hoverToolTip">Data</div>

Then you need to setup the javascript to load the data:

    title: hoverGetData,
    html: true,
    container: 'body',

The important piece of this is the title attribute which specifies the function to use to load the data.

I found that you MUST cache the result or bootstrap will request the data twice which results in this crazy function:

var cachedData = Array();

function hoverGetData(){
    var element = $(this);

    var id ='id');

    if(id in cachedData){
        return cachedData[id];

    var localData = "error";

    $.ajax('/your/url/' + id, {
        async: false,
        success: function(data){
            localData = data;

    cachedData[id] = localData;

    return localData;

Quick Tip: Setting Up Ionic for Sass

I’ve been working with Ionic on a PhoneGap application and one of the cool things that it supports is using SASS to generate the CSS file for your app. If you run the following command:

ionic setup sass

It will automatically download all the dependancies and setup your application so when you run:

ionic serve 

It will automatically start up gulp to process your sass files and start the server so you can work on your application.