Project

General

Profile

« Previous | Next » 

Revision 8221

lib/db_xml.py: put_table(): Fixed bug where also need to advance start to fetch next set when table is a view, because the views that are now being used with the import (inputs/FIA/occurrence_all/) are static rather than dynamic and do not return different rows after the previous set of rows has been imported

View differences:

lib/db_xml.py
221 221
        return put(db, node, row_ins_ct_ref, on_error, col_defaults)
222 222
    
223 223
    in_table = sql_gen.as_Table(in_table)
224
    is_view = sql.view_exists(db, in_table)
225 224
    sql_io.mk_errors_table(db, in_table)
226 225
    in_table.set_srcs([in_table], overwrite=False)
227 226
    db.src = strings.ustr(in_table)
......
254 253
        
255 254
        this_ct = cur.rowcount
256 255
        total += this_ct
257
        if not is_view: start += this_ct # advance start to fetch next set
258 256
        if this_ct == 0: break # in_table size is multiple of partition_size
259 257
        
260 258
        # Import data

Also available in: Unified diff