Next / Previous / Index / ITC Help System / Publications / Site map / NM Tech homepage

Creating a Sybase composite index

Tech Computer Center logo

Use a composite index when two columns are logically connected, such as a city and a zip code. They can not be created on text or image datatypes.

At the end of each command press the space-bar or press enter before continuing the next step.

  1. To create a composite index, type
            create index
  2. Type the name for the index.
  3. Type
            on
  4. Type the name of the table you are creating an index on.
  5. Since composite indexes use more than one column, you need to group them in parenthesis and separate the columns by a comma. Type
            (
  6. Type the first column name you want to create the index on.
  7. For each subsequent column you want to include in the index, type a comma, then the column name.
  8. Type
            )
  9. Type
            go
  10. Press Enter.

If everything goes well, you see the database prompt (a period, the name of the database you are using, another period, the number one and then the greater than symbol).


Next: Example of a Sybase composite index
See also: Indexing Sybase tables
Previous: Example of a Sybase unique index
Site map
Index: Keyword index to help pages
Help: New Mexico Tech Information Technology and Communications: Help System
ITC Publications
To report a problem: File a ticket
Send mail to the User consultant on duty or call them at 575-835-5437
Home: About New Mexico Tech

Maintained by John Shipman, john@nmt.edu; original by Steve Anderson
Last updated: 1997/06/23 22:21:59 UT
URL: http://www.nmt.edu/tcc/help/db/sybase/composite.html
QR two-dimensional bar code