Fixed issue with patches table.  upgraded column now has a default value of 0 and cannot be NULL