fix null ref bug and trigger column types