server/sources/native.py
branchstable
changeset 6128 fbb8398f80dc
parent 6019 373a313ee9ec
child 6142 8bc6eac1fac1
child 6201 cf445fcaf8fe
equal deleted inserted replaced
6127:747e423093fc 6128:fbb8398f80dc
   503         self.doexec(session, query, self.merge_args(args, qargs))
   503         self.doexec(session, query, self.merge_args(args, qargs))
   504 
   504 
   505     def manual_insert(self, results, table, session):
   505     def manual_insert(self, results, table, session):
   506         """insert given result into a temporary table on the system source"""
   506         """insert given result into a temporary table on the system source"""
   507         if server.DEBUG & server.DBG_RQL:
   507         if server.DEBUG & server.DBG_RQL:
   508             print '  manual insertion of', results, 'into', table
   508             print '  manual insertion of', len(results), 'results into', table
   509         if not results:
   509         if not results:
   510             return
   510             return
   511         query_args = ['%%(%s)s' % i for i in xrange(len(results[0]))]
   511         query_args = ['%%(%s)s' % i for i in xrange(len(results[0]))]
   512         query = 'INSERT INTO %s VALUES(%s)' % (table, ','.join(query_args))
   512         query = 'INSERT INTO %s VALUES(%s)' % (table, ','.join(query_args))
   513         kwargs_list = []
   513         kwargs_list = []