'Convert a MySQL\'s 64 bit, variable length binary string to a long.
TODO: this is MySQL-db, pyodbc specific.  OurSQL and mysqlconnector
already do this, so this logic should be moved to those dialects.'

def result_processor(self, dialect, coltype):

    def process(value):
        if (value is not None):
            v = 0
            for i in map(ord, value):
                v = ((v << 8) | i)
            return v
        return value
    return process
