This reverts ce3e002c02628e22226e838860eefa87c92063d1 which was meant for MySQL. here we use sqlite3