Re: Indexes on SQL Server 7.0



On 26 Mar 2007 21:29:32 -0700, othellomy@xxxxxxxxx wrote:

Doesn't seem to be to be very beneficial to have an index that only
includes the primary key. So for example I'm thinking of creating an
index for MatterConflicts that includes the fields: MatterConflicts,
Matters, and HitMatters.

no. Don't use composite indexs as they seldom are useful.

Hi othellomy,

Do you have any source for that sweeping statement?

AFAIK, composite indexes can be VERY useful. For queries that filter or
join on two or more columns, a composite index is much better than
seperate indexes on the individual columns.

--
Hugo Kornelis, SQL Server MVP
My SQL Server blog: http://sqlblog.com/blogs/hugo_kornelis
.



Relevant Pages

  • Re: Most efficient way to process this set of records??? (Bill Vaughn)
    ... I thought Bill's books were strictly for SQL Server. ... What I mean by "Composite" record is a group of columns from several ... Use datarelation between a master to the new detail (as opposed to ...
    (microsoft.public.dotnet.framework.adonet)
  • Re: Most efficient way to process this set of records??? (Bill Vaughn)
    ... I am more a dotNet guy than a SQL server guy, this seems for me typical a ... What I mean by "Composite" record is a group of columns from several ... Use datarelation between a master to the new detail (as opposed to ... procedure to setup command parameters and retrieve a master record, ...
    (microsoft.public.dotnet.framework.adonet)
  • Re: One column is nullable on the composite key
    ... Andy writes: ... > I would like to have a composite PK on 3 columns, ... > CREATE TABLE TableA ( ... Books Online for SQL Server SP3 at ...
    (microsoft.public.sqlserver.programming)
  • One column is nullable on the composite key
    ... ALTER TABLE TableA ADD ... SQL Server does not allow having a composite PK with one nullable column: ...
    (microsoft.public.sqlserver.programming)