Skip to main content

Text Input Tool Icon 文本输入工具

用户角色要求

用户角色*

工具/功能访问

完整用户

✓

基本用户

✓

*适用于 Designer 版本 2025.1+ 上的 Alteryx One专业版和企业版客户。

使用文本输入工具手动输入文本,可创建小型数据输入文件。您还可以在构建工作流期间使用此工具测试和创建查找表。

文本输入工具输入的数据已存储在工作流中,因此您可以直接共享该工作流,无需提供输入数据文件。

单个工具示例

此工具具有单个工具示例。转到示例工作流,了解如何在 Designer 中直接访问此示例和许多其他示例。

文本输入工具与 AMP

文本输入工具会根据您的工作流使用 Alteryx Multi-threaded Processing (AMP) 还是原始引擎,创建不同的数据类型。

  • AMP:文本输入工具会创建一个最大长度(可达 2,147,483,647 个字符)的 V_String 数据类型。

  • 原始引擎:文本输入工具会创建一个字符串数据类型,其长度与通过文本输入工具输入的最长字符串一致。

请注意,虽然 V_String 在 Designer 中处理时仅消耗存储其所含数据的必要内存,但我们仍建议您在写入数据库之前使用选择工具或 AutoField 工具设置更精确的字符串长度。

此外,当您使用文本输入工具时,AMP 引擎提供比原始引擎更可靠、更明确的数据类型定义。

  • 原始引擎:自动将某些字母值(如“F”和“T”)转换为布尔值 False 和 True。这可能会导致在输入单个字符的字符串时出现意外的类型转换。

  • AMP:不会自动将“F”或“T”转换为布尔值。除非明确定义为布尔值,否则这些值将保留为字符串。这可避免意外的类型更改,并提供更可预测的行为。

To keep the values you enter as strings without type detection on either engine, turn off automatic column detection. Go to Disable Automatic Column Detection.

配置工具

  1. 选择单元格以输入数据值。工具会根据您输入的值自动配置数据类型。

  2. 要重命名字段名称,请选择标题单元格并输入新的标题名称。

选项菜单

在配置窗口中,您可以通过选项工具栏执行多项操作。选项包括:

  • 导入:浏览以找到现有数据文件或连接。“文本输入”工具的限制是在导入时不能超过 10,000 个单元格,但是可以手动添加更多单元格(如有需要)。

  • 复制:将所选值复制到剪贴板上。

  • 粘贴:将剪贴板中的值粘贴到单元格中。

  • 删除:选项包括:

    • 全部:删除网格中的所有数据。

    • 行:删除当前选定行。

    • 列:删除当前选定列。

    • 标题:删除整个标题行。

  • 插入:选项包括行、列和标题插入。

任何空白单元格都会导致 NULL 值。

使用键盘在单元格之间导航

  • 按 Tab 键可将光标从左向右移入单元格。

  • 按 Shift+Tab 键可将光标从右单元格移动到左单元格。

  • 向上和向下箭头键可以将光标从一行的单元格移动到另一行的单元格中。

有关输入、输出、注释和错误属性的信息,请访问工具配置。

Disable Automatic Column Detection

重要

Automatic Column Detection is on by default, and workflows saved before this option existed (before 2026.4) keep their current behavior.

This option works with both the original engine and the AMP engine.

By default, the Text Input tool detects field types and sizes from the values you enter. Turn off automatic field detection to output your values as strings instead. The tool doesn't determine field types or shorten field sizes in your data. Turn off automatic field detection when you need to:

  • Keep leading zeros in identifiers, such as 00123.

  • Keep large numbers that look like numeric values.

  • Keep date-like text as entered.

  • Get predictable output field types and sizes.

To turn off automatic column detection, follow these steps:

  1. Select the Text Input tool.

  2. In the Configuration window, select the Disable Automatic Column Detection checkbox.

When the automatic column detection is off:

  • Values are output as strings. Use a Select tool or Auto Field tool later in your workflow to set the column types you need.

  • Column names, column order, and the way blank cells become NULL values don't change.

  • The option is saved with the tool configuration.