SQL Server Performance

adding foreign key constraint

Discussion in 'General Developer Questions' started by nilayinc, Oct 29, 2003.

  1. nilayinc New Member

    What is the exact syntax for adding a foreign key constraint on an existing column, without dropping the column ?
  2. Twan New Member

    alter table add constraint <name> foreign key ( <colname1>, <colname2> ) references <table>( <col1>, <col2> )


    More in Books Online under ALTER TABLE
  3. satya Moderator

    And take a reference from BOOKS ONLINE for code example.

    Satya SKJ

Share This Page