Database - (rows or records, columns or fields)? Database - (rows or records, columns or fields)? oracle oracle

Database - (rows or records, columns or fields)?


Row and record can arguably be considered as the same thing.

Fields and columns are different, a field is the intersection of a row and a column.
i.e. if your table has 10 rows and 10 columns, it has 100 fields.

When you create a table using DDL statements, you define columns (metadata).When you add rows using DML statements, you define rows and their fields.


In a broader sense, rows and columns refers to a matrix structure. When a database, not limited to a relational database, has a matrix structured data, it can be borrowed this terminology, but there might be a more specifical one.

In relational databases, for example, a table is always a matrix, so at each column in a table corresponds a field in a record and at each row corresponds a record: different concepts pointing to the same object.

A field can be present even in NoSQL databases, where often there's a free schema (no columns) and each row can have a different number of fields.

Similarly, a record can be a complex value in non-relational databases: it can contain fields with multiple distinct values (not 1NF). A row (a tuple in relational algebra) otherwise contains a single value for each field.


As stated in a previous answer to this question, row and record can arguably be used interchangeably.

Column and field can also arguably be used interchangeably. See the following article:Column (database)Here's a quote (as of this writing), from the article mentioned above, which makes that point:

"The term field is often used interchangeably with column, although many consider it more correct to use field (or field value) to refer specifically to the single item that exists at the intersection between one row and one column."


Here's some additional background info which may be helpful:

During my IT career as an analyst and programmer, I've typically used the terms field and record, not column and row, in both programming and relational database contexts. I think that comes from the instruction that I received during my university studies, and the fact that I learned the basic data hierarchy of bit, byte, field, record, file, before learning about relational databases.In researching this question, I found that it is common practice, and arguably correct, to use row and record interchangeably and to use column and field interchangeably. I was actually quite surprised, though, when my research indicated that row and column are preferred terms over record and field, in database terminology.