There are a lot of subtle differences in all the queries, thats why  didn't do a function. Some are fetchall(), some are fetchone(), some are execute(), some are executemany(). For me it was easier just to do them all separately.