在条件语句运行后如何以编程方式停止 python 脚本。在下面的伪脚本中:
for row in rows:
if row.FIRSTDATE == row.SECONDDATE:
pass
else:
print "FIRSTDATE does not match SECONDDATE " + row.UNIQUEID
## If I set my quit sequence at the this tab level, it quits after the first
## unmatched record is found. I don't want that, I want it to quit after all the
## unmatched records have been found, if any. if all records match, I want the
## script to continue and not quit
sys.quit("Ending Script")
谢谢,迈克