Project

General

Profile

« Previous | Next » 

Revision 2765

sql.py: mk_select(): Assert that fields list is non-empty

View differences:

lib/sql.py
538 538
    # Columns
539 539
    query += '\n'
540 540
    if fields == None: query += '*'
541
    else: query += '\n, '.join(map(parse_col, fields))
541
    else:
542
        assert fields != []
543
        query += '\n, '.join(map(parse_col, fields))
542 544
    
543 545
    # Main table
544 546
    query += '\nFROM '+table0.to_str(db)

Also available in: Unified diff