Unique index on multiple column primary key (composite)

  • I'm trying to create a Unique Index on composite primary key column(ColA, ColB) for Full Text Indexing. I could create the index, but I'm not able to create a full text index based on that.

    Any pointers? Appreciate help. Thanks, Srinivas.

  • What datatype are your two columns.

    Can you post the create fulltext index command.


    Cursors never.
    DTS - only when needed and never to control.

  • Both are integer columns(Item_Id int, Attribute_id int). And I'm trying to create the Full Text Index using SSMS(Management Studio). Unique index was created successfully. Trying to create Full Text Index by using it in SSMS it asks for a unique index. but my index does not show up in the drop down.

  • Per MSDN:

    KEY INDEX index_name

    Is the name of the unique key index on table_name. The KEY INDEX must be a unique, single-key, non-nullable column. Select the smallest unique key index for the full-text unique key. For the best performance, we recommend an integer data type for the full-text key.

    It has to be single-key. That means one column. Can't be compound.

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • I think I got it. I created a dummy Identity column on TableC and used it as an unique index for my Full Text Index. And it works. 🙂

  • srinivas-406082 (11/12/2010)


    I think I got it. I created a dummy Identity column on TableC and used it as an unique index for my Full Text Index. And it works. 🙂

    Cool biz. Well done.

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • please , for any table have you linked the table TableC , can you show us the database shema, i have the same problem , and i'm lookin for a solution since 3 days . please . thx in advance

  • Please note: 4 year old thread. Please post new questions in a new thread. Thank you.

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass

Viewing 8 posts - 1 through 7 (of 7 total)

You must be logged in to reply to this topic. Login to reply