2.2 Text Input & Directory Tools

Key Takeaways

  • The Text Input tool allows manual creation of static data tables directly on the workflow canvas without any external file or database dependencies.
  • Text Input data is embedded directly into the workflow's XML (.yxmd), ensuring 100% portability when sharing workflows across machines or servers.
  • The Text Input tool automatically infers data types and sizes string columns to the exact character length of the longest value entered in each column.
  • The Directory tool scans a file system path and outputs a standardized dataset of file metadata, including FullPath, Directory, FileName, CreationTime, LastWriteTime, and SizeBytes.
  • Combining the Directory tool with a Sort tool (LastWriteTime Descending) and Sample tool (First 1) is the standard pattern for dynamically grabbing the latest file in a directory.
Last updated: August 2026

2.2 Text Input & Directory Tools

Core Certification Focus: Understand when to use Text Input versus external files, how Text Input auto-assigns data types and string lengths, and the exact metadata fields generated by the Directory tool (especially FullPath, FileName, CreationTime, LastWriteTime, and SizeBytes).


1. Text Input Tool Architecture & Capabilities

The Text Input tool (In/Out palette) allows you to manually type or paste small datasets directly onto the canvas. It requires no external connection, making it ideal for self-contained workflows.

Primary Use Cases

  1. Lookup & Mapping Tables: Creating static reference tables (e.g., State Code → State Name, Department ID → Department Head) for Join or Find Replace tools.
  2. Testing & Prototyping: Providing isolated test data to validate complex Formula expressions or RegEx parsing logic without relying on massive production files.
  3. Dynamic Configuration Streams: Supplying control parameters or file paths into iterative macros and Dynamic Input tools.
+-----------------------------------------------------------------------------+
|                         TEXT INPUT TOOL ON CANVAS                           |
|                                                                             |
|   (No Input)  --->  [   Text Input   ]  --->  (1 Output Anchor: Output Data)|
|                            (Green)                                          |
+-----------------------------------------------------------------------------+

2. Text Input Data Entry & Type Inference

You can populate a Text Input tool by:

  • Direct Cell Entry: Clicking into cells to type values, using Tab to navigate columns and Enter to create new rows.
  • Copy / Paste: Copying cell ranges from Microsoft Excel, Google Sheets, or delimited text and pressing Ctrl + V inside the Text Input configuration window.
  • Context Menu Operations: Right-clicking cells to Insert Row, Delete Row, Insert Column, or Delete Column.
+-----------------------------------------------------------------------------+
|                     TEXT INPUT CONFIGURATION WINDOW                         |
+-----------------------------------------------------------------------------+
|    | Region_ID | Region_Name  | Target_Sales | Active | Launch_Date         |
|----+-----------+--------------+--------------+--------+---------------------|
| 1  | 101       | Northeast    | 500000.00    | True   | 2026-01-15          |
| 2  | 102       | Southeast    | 450000.00    | True   | 2026-02-01          |
| 3  | 103       | Midwest      | 380000.00    | False  | 2026-03-10          |
| 4  | 104       | West         | 620000.00    | True   | 2026-04-05          |
+-----------------------------------------------------------------------------+

Automatic Type Inference Rules & Traps

When you run a workflow, Alteryx examines the data entered in the Text Input tool and automatically assigns field types:

  • Whole Numbers: Assigned as Byte, Int16, Int32, or Int64 depending on magnitude.
  • Decimal Numbers: Assigned as Double or FixedDecimal.
  • Booleans: Text entries of True or False are inferred as Bool.
  • Dates: Strings formatted strictly as yyyy-mm-dd are inferred as Date.
  • Strings: Inferred as String or V_String.

[!WARNING] Critical Exam Trap: Exact String Auto-Sizing The Text Input tool sets the byte size of a String column to the exact length of the longest value in that column at configuration time. In the table above, the longest Region_Name is "Northeast" (9 characters). Alteryx assigns Region_Name a type of String with size 9. If you later join or union this stream with external data containing "Pacific Northwest" (17 characters), the downstream data will be truncated to 9 characters unless you insert a Select Tool to increase the field size!


3. Directory Tool Overview & Configuration

The Directory tool (In/Out palette) scans a specified directory on a local or network file system and returns a list of all matching files along with their file system metadata.

+-----------------------------------------------------------------------------+
|                        DIRECTORY TOOL CONFIGURATION                         |
+-----------------------------------------------------------------------------+
| Directory:            [ C:\EnterpriseData\FinancialReports\               ] |
| File Specification:   [ Monthly_*.xlsx                                    ] |
| [X] Include SubDirectories                                                  |
+-----------------------------------------------------------------------------+

Configuration Options

  1. Directory: The folder path to search (e.g., C:\EnterpriseData\FinancialReports\).
  2. File Specification (Filter): Wildcard pattern defining which files to return. Defaults to *.* (all files). Examples:
    • *.csv → Returns all CSV files.
    • Sales_202?.xlsx → Returns Excel files matching specific single-character years.
  3. Include SubDirectories: When checked, recursively searches all subfolders within the target directory.

4. Directory Tool Output Schema Deep Dive

The Directory tool outputs a standardized tabular schema containing 10+ metadata fields for every matching file found:

Output Field NameData TypeDescription & Example Content
FullPathV_WStringComplete absolute path including drive, directories, filename, and extension.<br>(e.g., C:\Data\Reports\Q1_Sales.xlsx)
DirectoryV_WStringPath of the containing folder without the filename.<br>(e.g., C:\Data\Reports\)
FileNameV_WStringFilename and extension only.<br>(e.g., Q1_Sales.xlsx)
ShortFileNameV_WString8.3 DOS-compatible shortened filename.<br>(e.g., Q1_SAL~1.XLS)
CreationTimeDateTimeFile creation timestamp (yyyy-mm-dd hh:mm:ss).
LastWriteTimeDateTimeLast modified/saved timestamp (yyyy-mm-dd hh:mm:ss).
LastAccessTimeDateTimeLast accessed/opened timestamp.
SizeBytesInt64File size on disk measured in bytes. (e.g., 1048576 for 1MB).
AttributeArchiveBoolTrue if Windows Archive flag is active.
AttributeReadOnlyBoolTrue if file is marked read-only.
AttributeHiddenBoolTrue if file is marked hidden.
AttributeSystemBoolTrue if designated as an operating system file.

5. Practical Design Pattern: Ingesting the Most Recent File

A classic scenario tested on the Core exam is dynamically identifying and processing the single most recently updated file in a folder.

Step-by-Step Tool Pipeline:

  1. Directory Tool: Set Directory to C:\Incoming\ and File Specification to *.csv.
  2. Sort Tool: Sort LastWriteTime in Descending order (places newest file at Row 1).
  3. Sample Tool: Select First 1 Records (isolates the latest file).
  4. Dynamic Input Tool (or Macro): Reads the FullPath field to load the file contents.
+-------------+      +-------------+      +-------------+      +-----------------+
|  Directory  | ---> |    Sort     | ---> |   Sample    | ---> |  Dynamic Input  |
| (*.csv)     |      | (LastWrite  |      | (First 1)   |      | (Reads FullPath)|
|             |      |  Descending)|      |             |      |                 |
+-------------+      +-------------+      +-------------+      +-----------------+

6. Summary Comparison: Text Input vs. Input Data vs. Directory

FeatureText Input ToolInput Data ToolDirectory Tool
Data OriginWorkflow XML (.yxmd)External File or DBFile System Metadata
Portability100% portable (Self-contained)Requires external file accessScans local/network paths
Dynamic ChangesStatic; requires manual editUpdates when source file updatesUpdates when directory changes
Primary OutputTabular user dataTabular source dataFile metadata (paths, sizes, dates)
Loading diagram...
Automated Latest-File Processing Architecture
Test Your Knowledge

A user creates a static mapping table using the Text Input tool. The longest entry in the 'Department' field is 'HR' (2 characters). Later in the workflow, a Join tool joins this stream with an employee table containing department names like 'Engineering' (11 characters). What will happen to the 'Department' field if no Select tool is used?

A
B
C
D
Test Your Knowledge

Which field generated by the Directory tool provides the complete path to a file, including the drive letter, directory path, file name, and file extension?

A
B
C
D
Test Your Knowledge

An automated workflow must identify and ingest only the single newest file in a network folder where new files arrive daily. What sequence of tools correctly identifies this file?

A
B
C
D
Test Your Knowledge

What is the primary advantage of using a Text Input tool rather than an Input Data tool pointing to a local CSV file when building a small reference table of tax rates?

A
B
C
D