passed sqlite_now around to speed things up