Clean out any unreferencec scripts from the script table.
Clean out any unreferencec scripts from the script table.

Tidy up some of the inline SQL

junovitch/pkg,en90/pkg,Open343/pkg,en90/pkg,skoef/pkg,khorben/pkg,junovitch/pkg,skoef/pkg,khorben/pkg,Open343/pkg,khorben/pkg