How to format date into YYYY-MM-DD?

Hello,

I receive date in the following format “Monday, 26 May, 2025” from beds24. I’d like to save it into Airtable. When i use parseDate({{1.checkoutDate}} ; YYYY-MM-DD) i have the following error : Validation failed for 1 parameter(s).

  • Invalid date in parameter ‘fldOg15EmDlWDApm1’.

I also use formatDate but i have an error also.

Could tell me how to convert date ?

Thanks



1 Like

Hi @Davy

While using parseDate, the format has to be same as the received date:

1 Like

{{formatDate(now; “YYYY-MM-DD”)}}

1 Like

Thank you @Shornalatha for your answer but i’ve already test it and it does not work. Is there a kind of sandbox of make where we could test some function ?

1 Like

You can try this :

{{formatDate(parseDate(1.checkoutDate; "dddd, D MMMM, YYYY"); "YYYY-MM-DD")}}

1 Like

Thank you for your answer. I tried your solution and it does not work

1 Like

Hey there,

can you share the incoming bundle?

Is 1.checkoutDate a date variable already or is it something else?

If its a date variable already you can use formatDate() directly.

Welcome to the Make community!

{{ formatDate(parseDate(1.checkoutDate; "dddd, D MMM, YYYY"); "YYYY-MM-DD") }}

(copy-paste the above into the field, or type it exactly as shown)

You have not yet provided sufficient information to demonstrate the problem that would allow us to accurately reproduce the scenario and any error(s).

If you need further assistance, please provide the following:

Please provide the output bundles of module [1] by running the scenario (you can also get this without re-running your scenario from the History tab).

Click on the white speech bubbles on the top-right of each module and select “Download input/output bundles”.

A. Upload as a Text File

Save each bundle contents in a plain text editor (without formatting) as a bundle.txt file.

You can upload the file here by clicking on this button:

B. Insert as Formatted Code Block

If you are unable to upload files on this forum, alternatively you can paste the formatted bundles.
These are the two ways to format text so that it won’t be modified by the forum:

  • Method 1: Type code block manually

    Add three backticks ``` before and after the content/bundle, like this:

    ```
    content goes here
    ```

  • Method 2. Highlight and click the format button in the editor

Providing the output bundles will allow others to replicate what is going on in the scenario, especially if there are complex data structures (nested arrays and collections) or if external services are involved, and help you with mapping the raw property names from collections.

@samliew