fixed unique field filter, get ID for a new record, fixed save for NULL values