Fix condition check if post value and table id is null