trying to switch over from sqlite to sql