---
title: nsSortDescriptors
framework: swiftui
role: symbol
role_heading: Instance Property
path: swiftui/sectionedfetchresults/nssortdescriptors
---

# nsSortDescriptors

The request’s sort descriptors, accessed as reference types.

## Declaration

```swift
@MainActor @preconcurrency var nsSortDescriptors: [NSSortDescriptor] { get nonmutating set }
```

## Discussion

Discussion Set this value to cause the associated SectionedFetchRequest to execute a fetch with a new collection of NSSortDescriptor instances. The order of managed objects stored in the results collection may change as a result. Use care to coordinate section and sort updates, as described in SectionedFetchRequest.Configuration. If you want to use SortDescriptor instances, set sortDescriptors instead.

## See Also

### Configuring the associated sectioned fetch request

- [nsPredicate](swiftui/sectionedfetchresults/nspredicate.md)
- [sortDescriptors](swiftui/sectionedfetchresults/sortdescriptors.md)
- [sectionIdentifier](swiftui/sectionedfetchresults/sectionidentifier.md)
- [SectionedFetchResults.Section](swiftui/sectionedfetchresults/section.md)
