Prettified SQL error print.
Added missing sys.exit()
Error seems to be cought, unknown if rollback actually works.

Signed-off-by: Stefan <stefan.virtanen@abo.fi>