More upgrade sql script fixes

Signed-off-by: Noteworthy Software, Inc <online@noteworthysoftware.com>