Next Prev Up Top Contents Index

create-index

Function
Summary

Creates an index for a table.

Package

sql

Signature

create-index name &key on unique attributes database =>

Arguments

name

The name of the index.

on

The name of a table.

unique

A boolean.

attributes

A list of attributes.

database

A database.

Values

None.

Description

The create-index function creates an index called name on the table specified by on . The attributes of the table to index are given by attributes . Setting unique to t includes UNIQUE in the SQL index command, specifying that the columns indexed must contain unique values.

The default value of unique is nil . The default value of database is *default-database* .

Example
(create-index [manager]
   :on [emp] :unique t :attributes '([ename] [sal]))
See also

drop-index
create-table


LispWorks Reference Manual (Windows version) - 14 Dec 2001

Next Prev Up Top Contents Index