Connector Error - Events date/time

Hi Team,

I built a connector to pull in Events to fill in the Events Entity Type in my KG. The entities are failing however because the Start Date and End Date fields are not formatted the way the built in Entity Type is expecting. The error message isn’t clear though, can someone tell me what format the entity type is expecting so that the connector can successfully run and populate my KG with even entities? Thanks!

Emmy

1 Like

Hi Emmy,

I believe that ISO_8601 date/time should do the trick

There is a transform “Format Dates” in our connectors framework and ISO_8601 date/time is also what is accepted through our API.

transform

Hagen

If you just need the Date and not the Time, this format - 2008-02-19 - works. If your input is as you show (mm/dd/yyyy/h:mm am/pm), you could use a Find and Replace with a regex. The regex would be:

(\d{1,2})\/(\d{1,2})\/(\d{4})(\/.*)

It captures mm as $1, dd as $2, and yyyy as $3. Then, the replacment pattern would be:

$3-$1-$2

Note that the last parenthetical - (/.*) - probably isn’t necessary, but it creates a 4th capture group that ensures the last capture group that you care about - (\d{4}) - doesn’t pick up any stray garbage that would cause the resulting value to not be in the format that is expected.

Thank you both!!! :+1: