Convert integer to date

Registered Posts: 5
edited July 2024 in Using Dataiku

I want to extract the data for the last 6 months but I have a problem with the date format of my field.

On attachments you can see my column ANNEE_MONTHS and I want to convert this column to date format.

I try this but It can't works :

SELECT *, DATE_FORMAT(annee_months, "%Y/%m") as date_format

I try to use a prepare recipe with a "Format date with custom format" but It can't works (the screen is on the attachments).

I don't know how to proceed.

Best Answer

  • Dataiker, Dataiku DSS Core Designer, Registered Posts: 135 Dataiker
    Answer ✓

    To extract the date you should Parse to standard date format in the prepare recipe:

    Screenshot 2023-10-03 at 19.13.25.png

    "Format date with custom format" can be used to convert the Date type to a string representation following a given format.

Answers

Welcome!

It looks like you're new here. Sign in or register to get started.

Welcome!

It looks like you're new here. Sign in or register to get started.