fixed problems with scripts
This now creates a table to store scripts that have been run