expanded example to include field filtering; minor bug fixes