equal
deleted
inserted
replaced
1162 @_open_only |
1162 @_open_only |
1163 def system_sql(self, sql, args=None, rollback_on_failure=True): |
1163 def system_sql(self, sql, args=None, rollback_on_failure=True): |
1164 """return a sql cursor on the system database""" |
1164 """return a sql cursor on the system database""" |
1165 if sql.split(None, 1)[0].upper() != 'SELECT': |
1165 if sql.split(None, 1)[0].upper() != 'SELECT': |
1166 self.mode = 'write' |
1166 self.mode = 'write' |
1167 source = self.cnxset.source('system') |
1167 source = self.repo.system_source |
1168 try: |
1168 try: |
1169 return source.doexec(self, sql, args, rollback=rollback_on_failure) |
1169 return source.doexec(self, sql, args, rollback=rollback_on_failure) |
1170 except (source.OperationalError, source.InterfaceError): |
1170 except (source.OperationalError, source.InterfaceError): |
1171 if not rollback_on_failure: |
1171 if not rollback_on_failure: |
1172 raise |
1172 raise |