In relational database theory, a relation is a set of tuples (d1, d2, ..., dj), where each element dn is a member of Dn, a data domain. Each distinct domain used in the definition of a relation is called an attribute, and each attribute is usually named.
A set of attributes (attribute names with their associated domains) is called a relation schema (or relation scheme). Sometimes a relation schema is taken to include a name for the relation itself. A relation schema is also called a table schema (or table scheme). A relation thus is seen as an instantiation of a relation schema.
Where all values of every attribute of a relation are atomic, that relation is said to be in first normal form.
|ID (Integer)||Name (String)||Address (String)|
|102||Yonezawa Akinori||Naha, Okinawa|
|202||Murata Makoto||Sendai, Miyagi|
|104||Sakamura Ken||Kumamoto, Kumamoto|
|152||Matsumoto Yukihiro||Okinawa, Okinawa|
In relational theory, but not in SQL, the tuples are unordered - one cannot say "The tuple of 'Murata Makoto' is above the tuple of 'Matsumoto Yukihiro'", nor can one say "The tuple of 'Yonezawa Akinori' is the first tuple."
Base relation variable and derived relation variable (view) 
Relation variables (relvars) are classified into two classes: base relation variables and derived relation variables. By applying a relational algebra expression or relational calculus expression to one or more relation variables, one new relation value is derived.
A base relation variable is a source relation variable which is not derived from any other relation variables. In SQL, a database language of relational database, the term base table can be roughly considered a base relation variable. By using a Data Definition Language (DDL), it is able to define base relation variables. In SQL, by using
CREATE TABLE syntax, it is able to define base relation variables. The following is an example.
CREATE TABLE List_of_people ( ID INTEGER, Name CHAR(40), Address CHAR(200), PRIMARY KEY (ID) )
A derived relation variable is a relation variable which is derived from one or more relation variables by applying a relational algebra expression or relational calculus expression. A View is considered a derived relation variable. A Data Definition Language (DDL) is used to define derived relation variables. In SQL,
CREATE VIEW syntax is used to define derived relation variables. The following is an example.
CREATE VIEW List_of_Okinawa_people AS ( SELECT ID, Name, Address FROM List_of_people WHERE Address LIKE '%, Okinawa' )
- E. F. Codd (Oct 1972). "Further normalization of the database relational model". Data Base Systems. Courant Institute: Prentice-Hall. ISBN 013196741X. "R is a relation on these n sets if it is a set of elements of the form (d1, d2, ..., dj) where dj ∈ Dj for each j=1,2,...,n ."
- Jeffrey D. Ullman (1989). Principles of Database and Knowledge-Base Systems. Jeffrey Ullman. pp. 410–. Retrieved 28 November 2012.
- Dennis Elliott Shasha; Philippe Bonnet (2003). Database Tuning: Priciples, Experiments, and Troubleshooting Techniques. Morgan Kaufmann. p. 124. ISBN 978-1-55860-753-8.
- Martyn Prigmore (2007). Introduction to Databases With Web Applications. Pearson Education. p. 101. ISBN 978-0-321-26359-9.
- T. A. Halpin; Antony J. Morgan; Tony Morgan (2008). Information Modeling and Relational Databases. Morgan Kaufmann. p. 772. ISBN 978-0-12-373568-3.
- Peter Rob; Carlos Coronel, Peter Rob (2009). Database Systems: Design, Implementation, and Management. Cengage Learning. pp. 190–. ISBN 978-1-4239-0201-0. Retrieved 28 November 2012.
- Michael F. Worboys (1995). Gis: A Computing Perspective. Taylor & Francis. pp. 57–. ISBN 978-0-7484-0065-2. Retrieved 22 November 2012.
- Codd, Edgar F (June 1970). "A Relational Model of Data for Large Shared Data Banks". Communications of the ACM (Association for Computing Machinery) 13 (6): 377–87. doi:10.1145/362384.362685. "The term relation is used here in its accepted mathematical sense"
- Date, C. J. (1994). An Introduction to Database Systems (6 ed.). Addison–Wesley. ISBN 978-0-201-82458-2.
- Date, C. J. (2005). Database in Depth : Relational Theory for Practitioners. Beijing: O'Reilly Media. ISBN 978-0-596-10012-4.