fixed jdbc nil checks