---
title: "enumeratorForChangeHistoryFetchRequest:error:"
framework: Contacts
role: symbol
role_heading: Instance Method
platforms: [iOS 13.0+, iPadOS 13.0+, Mac Catalyst 13.1+, macOS 10.15+, visionOS 1.0+, watchOS 6.0+]
path: contacts/cncontactstore/3294190-enumeratorforchangehistoryfetchr
---

# enumeratorForChangeHistoryFetchRequest:error:

Enumerates a change history fetch request.

## Declaration

```occ
- (CNFetchResult<NSEnumerator<CNChangeHistoryEvent *> *> *) enumeratorForChangeHistoryFetchRequest:(CNChangeHistoryFetchRequest *) request error:(NSError **) error;
```

## Parameters

- `request`: A description of the events to fetch.
- `error`: If the fetch fails, contains an [doc://com.apple.documentation/documentation/Foundation/NSError](foundation/nserror.md) object with more information.

## Return Value

An enumerator of the events matching the result, or `nil` if there was an error.

## Discussion

Executes the fetch request and returns an enumerator for the results. This can prevent all events from loading into memory at once. An error that occurs during enumeration may throw an exception.

## See Also

### Fetching change history info

- [currentHistoryToken](currenthistorytoken.md)
