<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def get_last_block(self, cur=None):
 """ Get the highest block last processed """

        sql = 'SELECT MAX(block_height) FROM {};'.format(self.subdomain_table)
        cursor = None
        if cur is None:
            cursor = self.conn.cursor()
        else:
            cursor = cur

        rows = db_query_execute(cursor, sql, ())
        height = 0
        try:
            rowdata = rows.fetchone()
            height = rowdata['MAX(block_height)']
        except:
            height = 0

        return height