# toDate

toDate() function is the Standard function available in 200OK.

**Description**  :  The toDate function converts the input date into the specified format.&#x20;

**Syntax** : fx\_toDate(date,yyyy-MM-dd))

**Example** : fx\_toDate(2022-03-31,yyyy-MM-dd) returns "2024-07-03", indicating the date formatted as year-month-day.

Here we go with simple scenario using the above function.

**Scenario**  :  In a data management system, users need to convert dates into a standardized format for consistent data processing. They utilize a function to convert dates into the format 'yyyy-MM-dd', ensuring uniformity across datasets. For instance, converting the date '2022-03-31' into 'yyyy-MM-dd' format returns '2024-07-03', facilitating streamlined data analysis and reporting.

\
**Request Side** :&#x20;

<figure><img src="https://lh7-us.googleusercontent.com/_9WLbiJ7NTV0mYByvlukQQgvUyLo5QjR67_WCX8ttgKfISkTpyAKlXHcO53TJVqZPbI-qjhKqFpd0td6FU4h3hRXWB-TlZznfa3pQ3eoij2kugcSwfuRjd7dhDJB1M8R_9cfiYuVnlPi72mzWQpmgyQ" alt=""><figcaption></figcaption></figure>

**Response Side** :&#x20;

<figure><img src="https://lh7-us.googleusercontent.com/tSk3gfy6lExk5R-U8SJpOnNMe0BeQb4hq30stNuu4Hl_m5yFzRMBTx5bRfh6eIinZxNmLrWcxSi84J5mWzZLf7EMCJx4FH6XwQWqdKjxqtz4pSkfuyNF5MxD3BiCDyz_9EJfmRX1qHRcIotHvO2Hnh8" alt=""><figcaption></figcaption></figure>

<figure><img src="https://lh7-us.googleusercontent.com/lMV_mVuZQZDhA0h1XXBeGmEide7GFDyteDaQQ_vLQ_P9OVH4ZepGgQ-mTK9sFmqNq_1Kp4EyCGkaV18oePekJN14ttWisiVy7B0-oG9l3dq0sfovhnuXdIrZvRC3yy2PHovH6uZfi5jcXz1ayLUitUY" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://200ok.gitbook.io/200ok-documents/user-manual/built-in-functions/date-and-time/todate.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
