# MID

#### Syntax <a href="#syntax.31" id="syntax.31"></a>

**MID**(*text*; *startPos*; *length*)

* *text* - The text from which a segment is to be returned *- **Value type**: text*
* *startPos* - The position of the first character of the segment within the text *- **Value type**: integer*
* *length* - The length of the returned segment in characters *- **Value type**: integer (optional).*

#### Remarks <a href="#remarks.25" id="remarks.25"></a>

* If *length* is not defined or *startPos* + *length* exceeds the length of the text, **MID** returns all characters after *startPos*.
* **MID** returns an empty text ("") if *startPos* is greater than the length of parameter *text* or if the parameter *length* is 0.&#x20;

#### Examples

<figure><img src="https://content.gitbook.com/content/4X6nN2wTlDsVpd8P1WDM/blobs/cHq9OFyX3A88MkaKqyCq/grafik.png" alt=""><figcaption></figcaption></figure>
