SQL scripts and test harness updated