Project

General

Profile

« Previous | Next » 

Revision 5582

csv2db: Removed no longer needed manual setting of use_copy_from, which defaults to True in sql_io.import_csv()

View differences:

csv2db
45 45
    
46 46
    table = sql_gen.Table(table, schema)
47 47
    
48
    use_copy_from = True
49
    
50 48
    # Loads data into the table using the currently-selected approach.
51 49
    def load():
52 50
        # Open input stream
......
55 53
        line_in = streams.ProgressInputStream(in_, sys.stderr, n=1000)
56 54
        
57 55
        # Import data
58
        try: sql_io.import_csv(db, table, line_in, use_copy_from)
56
        try: sql_io.import_csv(db, table, line_in)
59 57
        finally:
60 58
            line_in.close() # also closes proc.stdout
61 59
            proc.wait()

Also available in: Unified diff