Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

How to add Foreign key in a table after the creation of the
table?

Answer Posted / devi

alter table table2
add(constraint table2_col2_fk foreign key(col2) references
table1(col1);
here col2 is the foreign key of table2 which refer to the
col1 of table1 which is h epimary key of table1

Is This Answer Correct ?    3 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is a sql select statement?

1044


How do you copy a table in sql?

1077


How to avoid using cursors? What to use instead of cursor and in what cases to do so?

1198


Is t sql a programming language?

1073


Can we use views in stored procedure?

1042


how is myisam table stored? : Sql dba

1064


Define implicit and explicit cursors.

1150


What are analytic functions in sql?

1035


Enlist the advantages of sql.

1007


What are the advantages of stored procedure?

1006


What is pl sql in dbms?

956


What are sql triggers used for?

1004


What are the two parts of design view?

1023


Does google use sql?

971


Does truncate require commit?

979