Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Zero Record DateTime

CSmith16
8 - Asteroid

Hello,

 

I am running into an issue. We have data that is downloaded and imported through a dynamic input tool. We sometimes upload blank data (literally blank, no column names) for days that have no activity. Problem I'm running into is the workflow errors because tools reference column names that aren't present. I can filter the data to only give data that has a record count greater than 0 but that doesnt fix the DateTime tools that are missing a column.

 

Screenshot 2024-02-28 150054.png

5 REPLIES 5
apathetichell
18 - Pollux

create a 0 record text input tool with your needed schema (ie column names). Union it to your data stream. this will mandate that the column names are there at run time.

CSmith16
8 - Asteroid

Wow! when you put it that way it seems I missed out on this solution staring me right in the face. THANK YOU!!

apathetichell
18 - Pollux

All good! One note - I see these are feeding into date/time tools. I assume these are set up for strings? blank fields will be stored as bytes natively. so you may need a multi-field tool in front of your date/time.

 

VERY IMPORTANT:

select all from the dropdown of fields types.

 

select the fields.

toggle off the new field checkbox which I barely ever use.

 

toggle the type to string.

 

write tostring([_CurrentField_]) in the formula.

 

Key point - you must have this set for ALL in the top part of the tool - not for number - and not for string. This can cause something to break if it's configured wrong.

CSmith16
8 - Asteroid

Actually, I lucked out. All the fields coming in are V_WString.

 

Screenshot 2024-02-28 150054.png

CSmith16
8 - Asteroid

Even better, found this neat macro:

 

Screenshot 2024-02-28 150054.png

Screenshot 2024-02-28 150054.png

Labels