Skip to Content
Jun 15, 2021 at 04:25 PM

Generating Y/N attribute from date?

68 Views Last edit Jun 15, 2021 at 08:06 AM 2 rev

Hello Community

I'd like to create a column on file import of a model, which checks if a date is in another column or not and gets filled with Y or N.

In pseudo code:

if date != empty:
    return "Y"
    return "N"

Is this possible? I can't check the date column with if (isnull(), "N", "Y" ) and I need an easy switch for viewers of the story. Think about a column "Date of order finished" and I need to filter for finished and not finished orders with the push of a button.

Any idea on how to approach this? So far I'm enriching the data with a Python script - but that can't be the solution forever. We could use Python for the dashboard then.

Additional information: The data gets uploaded within a model. Maybe that's the wrong approach?