Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Converting SQL to relational algebra [closed]

Does anyone know any good online resources which I can use to practise SQL to relational algebra conversion?

like image 355
user559142 Avatar asked Apr 24 '11 15:04

user559142


People also ask

How do you translate SQL queries into relational algebra?

Translating SQL Queries into Relational AlgebraA query is at first decomposed into smaller query blocks. These blocks are translated to equivalent relational algebra expressions. Optimization includes optimization of each block and then optimization of the query as a whole.

What is the relationship between SQL and relational algebra?

Relational algebra is a useful theoretical language that serves to define more complex languages. The second language we consider, Structured Query Language or SQL, is a practical language that allows a high-level expression of queries.

What is relational algebra How is it different from SQL statements?

The SQL includes only some features from the relational algebra. SQL is based to a greater extent on the tuple relational calculus. 7. Relational Algebra is one of the languages in which queries can be expressed but the queries should also be expressed in relational calculus to be relationally complete.

What are the limitations of relational algebra?

Relational algebra cannot perform arithmetic operations. It is unable to do aggregation operations even it cannot compute transitive closure. It cannot modify the data present in the database.


2 Answers

See: http://db.grussell.org/index.html
The following powerpoint presentation may also be of help:
http://www.cs.wayne.edu/~shiyong/csc6710/slides/kiferComp_348761_ppt05.ppt

like image 177
Johan Avatar answered Sep 30 '22 09:09

Johan


The online tool RelaX will allow you to convert SQL to Relational Algebra. You can also compose and execute relational algebraic expressions on small datasets.

like image 37
mstahl Avatar answered Sep 30 '22 11:09

mstahl