Import xlsx double column as string
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
In my excel file my column is a general format.
I have various values in this column , ie:
Field |
0 |
FY21DP |
FY22DP |
FY20DP |
Y |
FYDP22 |
FY 22DP |
FY22DP (Y) |
Yes |
why is this being read in as a double? Can I read it in as a string without doing anything to the excel workbook?
- Labels:
- Custom Tools
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi @wonka1234
Can you share the input file/workflow? Here using just what you pasted, it is being interpreted as string (as expected):
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
It's read as a double since the first value is a "0". You can alter it just by adding a select tool after it OR by importing it from a row after the first one :-).
EDIT -> My thinking is wrong. As @Felipe_Ribeir0 said, even when i put the rows in a Excelfile, it reads it as a string field.
This might give us a clue:
Solved: Alteryx Input Tool Reading a String data type Colu... - Alteryx Community
Do the first thousand records contain numbers? Then it will probably show up as a double as it seems to determine the type based on the first thousand rows.
Greetings,
Seb
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
First few rows in excel look like this:
My alteryx first few rows look like this:
Currently being read in as a double into alteryx
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Can you input that excel input sheet, as it shows as N/A, need to understand the value in it.
Many thanks
Shanker V
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
@ShankerV it is actually a vlookup formula in the excel sheet
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi @wonka1234
Actually the solution provided by my friend @Felipe_Ribeir0 should have resolved your issue.
As it still persists it might be caused due to some hidden issue. Hence requested to share the file where me or my fellow friends in alteryx community can input in our Alteryx and provide the solution.
Shanker V
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
No the select tool doesnt solve it! i wonder if its the way its being imported.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
SEems like anything other then "0" is being read as NULL
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
@wonka1234 - Since the column is generated by a VLOOKUP statement, Can you add to the formula to decode the "#N/A" value into another value that is text like "NA"? For example, you could wrap an IFNA() formula around the VLOOKUP statement or convert to XLOOKUP depending on your version of Excel.
Expanding on the 1000 row thought, if the first 1000 rows only show 0's and "#N/A" values then perhaps Alteryx is interpreting that to be numbers and nulls and thus defaults to double.
Good luck.
