Bring your best ideas to the AI Use Case Contest! Enter to win 40 hours of expert engineering support and bring your vision to life using the powerful combination of Alteryx + AI. Learn more now, or go straight to the submission form.
Start Free Trial

Alteryx Designer Desktop Discussions

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

Why is the size of V_String a huge integer?

nyck3333
8 - Asteroid

From the Python tool example, what is 2147483647?

 

Industry': {'type': 'V_String',
  'length': 2147483647,
  'source': 'TextInput:',
  'description': ''},
 'Name': {'type': 'V_String',
  'length': 2147483647,
  'source': 'TextInput:',
  'description': ''},
 'Age': {'type': 'Int32',
  'length': 4,
  'source': 'TextInput:',
  'description': ''},
 'YearsOfEducation': {'type': 'Int32',
  'length': 4,
  'source': 'TextInput:',
  'description': ''},
 'YearsAtCurrentJob': {'type': 'Int32',
  'length': 4,
  'source': 'TextInput:',
  'description': ''},
 'Salary': {'type': 'Int32',
  'length': 4,
  'source': 'TextInput:',
  'description': ''}}
In [5]:
 
 
 
 
 
# write out the data with the original
2 REPLIES 2
Yoshiro_Fujimori
15 - Aurora
15 - Aurora

Hi @nyck3333 ,

 

To directly answer to your question, 

2,147,483,647 = 2^31 − 1.

Though I don't have any evidence, I guess V_String data type deals with the characters in it with the index of 32 bit length.

 

And V_String does not use up your disk.

The help page https://help.alteryx.com/20231/designer/data-types#string-data says;

"It is more efficient to store strings as variable-length strings.

This is because fixed-length strings reserve space for the specified number of characters,

and variable-length strings use only the amount of storage needed for the data in that cell.

Set a high limit for fixed-length strings to avoid truncating data."

 

So you can rest assured.

But if you are not sure, you may want to compare the size of output files with V_String and String with the same data.

danilang
19 - Altair
19 - Altair

Hi @nyck3333 

 

To summarize @Yoshiro_Fujimori's comment, the listed size is the maximum size of a V_String.  When running, only the actual length of the string(plus a little overhead) is allocated.

 

Dan

 

 

Labels
Top Solution Authors