> For the complete documentation index, see [llms.txt](https://suhantudor.gitbook.io/crud-node/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://suhantudor.gitbook.io/crud-node/reference/api-reference/tostring.md).

# toString

Returns a string that represents the current row.

{% hint style="info" %}
toString is the formatting method in the crud-node. It converts a row to its string representation so that it is suitable for display.&#x20;

The default implementation of the toString method returns the id of a document, and \<unknown> if a document is not defined.&#x20;

To override toString formatting, add to document schema toString method.
{% endhint %}

**Signature**

The same on all adapters

```javascript
toString(document?: IDocument<S>): string;
```

**Example**

<pre class="language-javascript"><code class="lang-javascript">enum EmployeeProps {
  _id = '_id',
  lastName = 'lastName',
  firstName = 'firstName',
  ....
}
<strong>
</strong><strong>...
</strong><strong>
</strong>toString: (data: IDocument&#x3C;EmployeeProps>) => {
    return `${data.firstName} ${data.lastName}`;
},
</code></pre>
