next up previous
Next: Exchange Format Basics Up: Database Basics Previous: Normalization

Queries

``Queries'' are used to extract and combine information from existing tables to produce new tables.

Relational databases provide these ``operators'' that can be composed into queries:

Example query:

{ (#accn:   x.#accn,
   #uid:    x.#uid, 
   #title:  x.#title, 
   #seq:    x.#seq,
   #f-start: y.#start, 
   #f-end  : y.#end, 
   #f-name : y.#name, 
   #f-anno : y.#anno)
| \x <- genpepts, \y <- features,
  y.#uid = x.#uid }

Can you see what operators made up the above query?

Note that a query is a sequence of purely structural operations. It does not care what the data is, what a column means. It merely, ``select'', ``project'', etc.



Wong Lim Soon
4/9/2000