Null check and taking systemId if username is empty