Get the current writer position

def get_writer_position(self, name):
        """Get the current writer position"""
        cursor = self.cursor
        cursor.execute('SELECT timestamp FROM gauged_writer_history '
                       'WHERE id = %s', (name,))
        result = cursor.fetchone()
        return result[0] if result else 0