Fixed SQL storage issue with UUIDs
Fixed hasFlag()