In the context of databases and data structures, a tuple is a collection of elements, typically a row in a table. Each element within a tuple is an atomic value, which means it cannot be further divided into smaller meaningful parts. In a relational database table, a tuple corresponds to a single record, which contains data for each column in that row.
For example, consider a simple table with three columns: “Name,” “Age,” and “City.” A tuple in this table might look like this:
(Name: “Alice”, Age: 30, City: “New York”)
This tuple represents one entry in the table, with “Alice” being the value for the “Name” column, 30 for the “Age” column, and “New York” for the “City” column. Each tuple in the table is unique and represents a single entity or observation.
表格里的行列又叫作什么
Row: tuple, record, observation
Column: attribute, feature, field
Table: relation