second fix to non-contiguous fields :-) add check table exists fn