Project

General

Profile

« Previous | Next » 

Revision 2324

sql.py: put_table(): Fixed bug where "add_row_num(db, out_pkeys_ref0)" was mistakenly put under the "if row_ct_ref != None" if statement

View differences:

lib/sql.py
821 821
        else:
822 822
            if row_ct_ref != None and cur.rowcount >= 0:
823 823
                row_ct_ref[0] += cur.rowcount
824
                add_row_num(db, out_pkeys_ref[0]) # for joining with input pkeys
825 824
            
826 825
            if has_joins:
827 826
                select_joins = insert_joins+[sql_gen.Join(out_table, join_cols)]
......
829 828
                run_query_into_pkeys(*mk_select(db, select_joins, pkeys_cols,
830 829
                    start=0))
831 830
            else:
831
                add_row_num(db, out_pkeys_ref[0]) # for joining with input pkeys
832
                
832 833
                db.log_debug('Getting input pkeys for rows in insert')
833 834
                run_query_into(db, *mk_main_select([in_pkey]),
834 835
                    into_ref=in_pkeys_ref)

Also available in: Unified diff