def _execute(self,<EOL>native,<EOL>command,<EOL>data=None,<EOL>returning=True,<EOL>mapper=dict):
if data is None:<EOL><INDENT>data = {}<EOL><DEDENT>with native.cursor() as cursor:<EOL><INDENT>log.debug('<STR_LIT>')<EOL>log.debug(command % data)<EOL>log.debug('<STR_LIT>')<EOL>try:<EOL><INDENT>rowcount = <NUM_LIT:0><EOL>for cmd in command.split('<STR_LIT:;>'):<EOL><INDENT>cmd = cmd.strip()<EOL>if cmd:<EOL><INDENT>cursor.execute(cmd.strip('<STR_LIT:;>') + '<STR_LIT:;>', data)<EOL>rowcount += cursor.rowcount<EOL><DEDENT><DEDENT><DEDENT>except pymysql.InterfaceError:<EOL><INDENT>raise orb.errors.ConnectionLost()<EOL><DEDENT>except (pymysql.IntegrityError, pymysql.OperationalError) as err:<EOL><INDENT>native.rollback()<EOL>if err[<NUM_LIT:0>] == <NUM_LIT>:<EOL><INDENT>raise orb.errors.DuplicateEntryFound(err[<NUM_LIT:1>])<EOL><DEDENT>reference_error = re.search('<STR_LIT>', nstr(err))<EOL>if reference_error:<EOL><INDENT>msg = '<STR_LIT>'<EOL>raise orb.errors.CannotDelete(msg)<EOL><DEDENT>log.debug(traceback.print_exc())<EOL>raise orb.errors.QueryFailed(command, data, nstr(err))<EOL><DEDENT>except pymysql.Error as err:<EOL><INDENT>native.rollback()<EOL>log.error(traceback.print_exc())<EOL>raise orb.errors.QueryFailed(command, data, nstr(err))<EOL><DEDENT>try:<EOL><INDENT>raw = cursor.fetchall()<EOL>results = [mapper(record) for record in raw]<EOL><DEDENT>except pymysql.ProgrammingError:<EOL><INDENT>results = []<EOL><DEDENT>return results, rowcount<EOL><DEDENT>
Executes the inputted command into the current \
connection cursor.

:param      command    | <str>
            data       | <dict> || None

:return     [{<str> key: <variant>, ..}, ..], <int> count