INVALID_FUNCTION_ARGUMENT Error

I have setup an ETL Pipeline and dumped csv files to S3 and then reading them to Quick sight using AWS Glue.

For some reason the refresh fails with the following error. I don’t understand what does it mean here.

image

The error you’re encountering likely indicates an issue with the format of date values in your data. Not sure from your post if you are using S3 or Athena as the data connector. Regardless you can check these things.

  • Ensure that date columns do not have values that are too short or incorrectly formatted compared to the expected format in QuickSight.
  • Verify that the date format in your CSV files matches the format expected by QuickSight. You can refer to the supported date formats documentation for QuickSight for more details.
  • Make sure all date values are uniform throughout the rows to avoid inconsistencies.
  • When using AWS Glue or Athena, be aware that they bring data in as strings, which can lead to different or inaccurate date formats.

Hello @robdhondt,

Thanks for you reply, I am not sure if that’s because of dates because this is the error I have received from today’s failed refresh message

Screenshot 2024-08-07 at 9.16.41 AM

Hello @robdhondt,

I was able to figure out what happened. Somehow the columns were jumbled up and date column has a value of “1716”. That was the reason it shows INVALID_FUNCTION_ARGUMENT.

I was able to align the columns properly and redo the refresh in QuickSight. But now I have a new issue with dates in date column 2024-08-05 00:00:00.000. Not able to properly format this date and I have tried yyyy-MM-dd HH:mm:ss.SSS to match the date format. But it’s not properly syncing this. What would be right format here?

1 Like

Hi @Manoj_Virigineni

Sounds like you still might have inconsistent data in your columns.You can try running a sql query like this in Athena to validate your date formats.

-- Validate the date formats
SELECT 
    date_column
FROM 
    sample_dates 
WHERE 
    NOT regexp_like(date_column, '^\d{4}-\d{2}-\d{2} \d{2}:\d{2}:\d{2}\.\d{3}$');
1 Like

Hi @Manoj_Virigineni,
It’s been awhile since we last heard from you, were you able to find a work around for your situation or did you have any additional questions?

If we do not hear back within the next 3 days, I’ll go ahead and close out this topic.

Thank you!

Hi @Manoj_Virigineni,
Since we haven’t heard back, I’ll go ahead and close this topic. However, if you have any additional questions, feel free to create a new topic in the community and link this discussion for relevant information.

Thank you!