> For the complete documentation index, see [llms.txt](https://simpldb.js.org/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://simpldb.js.org/documentation/collection/fetchall.md).

# .fetchAll()

Fetches all the entries from the collection directly from the JSON file.

### fetchAll()

| **Returns**                                                                                                                                                        | **Description**                     |
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ----------------------------------- |
| [Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[Data](https://simpldb.gitbook.io/docs/types-and-interfaces/data)> | All the entries from the collection |

```javascript
// Note: Users is a collection.

Users.createBulk([
  { id: 1, name: 'Peter' },
  { id: 2, name: 'Henry' }
]);

Users.fetchAll(); // [{ id: 1, name: 'Peter' }, { id: 2, name: 'Henry' }]
```
