Expression index

Expression index

An expression index is a database index that is built on a generic expression, rather than on a list of columns. This allows indexes to be defined for common query conditions that depend on data in a table, but are not actually stored in that table.

A common use for an expression index is to support case-insensitive searching or constraints. For example, if a web site wants to make user names case-insensitive, but still preserve the case as originally entered by the user, a unique index can be created on the upper- or lower-case representation of the user name:

:CREATE UNIQUE INDEX site_user__user_name_lower ON site_user( lower( user_name ) );

That will create a unique index on "lower(user_name)". Any queries that search on "lower(user_name)" could then make use of that index:

:SELECT user_id FROM site_user WHERE lower(user_name) = lower('Decibel');


Wikimedia Foundation. 2010.

Игры ⚽ Нужно сделать НИР?

Look at other dictionaries:

  • Index on Censorship — is a magazine founded in 1972 by Michael Scammell [ Michael Scammell, How Index on Censorship Started in George Theiner They Shoot Writers, Don t They? (Faber Faber, London, 1984, pp. 19 28.)] and a group of writers, journalists and artists, led… …   Wikipedia

  • Index Librorum Prohibitorum — Index Librorum Prohibitorum, 1564. L Index librorum prohibitorum (index des livres interdits) aussi appelé Index expurgatorius, Index librorum prohibitorum juxta exemplar romanum jussu sanctissimi domini nostri est une liste d ouvrages que les… …   Wikipédia en Français

  • Index Des Notations Musicales — Le but de cette page est de permettre la reconnaissance de symboles inconnus sur une partition. Les éléments graphiques sont repris d autres pages, et devraient être créés plus spécifiquement pour ne contenir que la représentation graphique du… …   Wikipédia en Français

  • Index notations (musique) — Index des notations musicales Le but de cette page est de permettre la reconnaissance de symboles inconnus sur une partition. Les éléments graphiques sont repris d autres pages, et devraient être créés plus spécifiquement pour ne contenir que la… …   Wikipédia en Français

  • Index (Rome) — Index Librorum Prohibitorum Index Librorum Prohibitorum, 1564. L’Index librorum prohibitorum (index des livres interdits) aussi appelé Index expurgatorius, Index librorum prohibitorum juxta exemplar romanum jussu sanctissimi domini nostri est une …   Wikipédia en Français

  • Index Expurgatorius — Index Librorum Prohibitorum Index Librorum Prohibitorum, 1564. L’Index librorum prohibitorum (index des livres interdits) aussi appelé Index expurgatorius, Index librorum prohibitorum juxta exemplar romanum jussu sanctissimi domini nostri est une …   Wikipédia en Français

  • Index expurgatorius — Index Librorum Prohibitorum Index Librorum Prohibitorum, 1564. L’Index librorum prohibitorum (index des livres interdits) aussi appelé Index expurgatorius, Index librorum prohibitorum juxta exemplar romanum jussu sanctissimi domini nostri est une …   Wikipédia en Français

  • expression — ex·pres·sion n 1: an act, process, or instance of representing or conveying in words or some other medium: speech protected expression under the First Amendment 2: a mode or means of expressing an idea, opinion, or thought ◇ An expression is… …   Law dictionary

  • Index des Estampes de Breugel l'Ancien — Index des Estampes de Bruegel l Ancien Le Printemps, 1565 Sur les Estampes de Pieter Bruegel l Ancien, seul deux grands spécialistes se sont penchés successivement. René Van Bastelaer et Louis Lebeer, tous deux conservateur honoraire du Cabinet… …   Wikipédia en Français

  • Index des Estampes de Bruegel l'Ancien — Le Printemps, 1565 Sur les Estampes de Pieter Bruegel l Ancien, seul deux grands spécialistes se sont penchés successivement. René Van Bastelaer et Louis Lebeer, tous deux conservateur honoraire du Cabinet des Estampes de la Bibliothèque royale… …   Wikipédia en Français

Share the article and excerpts

Direct link
Do a right-click on the link above
and select “Copy Link”