I have two tables miusernames with columns where UserNamesID is the primary key for table miusernames..
UserNamesID UserName
1 senthil
2 robert
and miemailids with columns where Emailid is the primary key for table miemailids ..
Emailid UserNamesID
1 2
I forgot to create column UserNamesID in table miemailids as foreign key relationship with parent table miusernames .. I need values of column UserNamesID in table miemailids should not be the values other than values in UserNamesID column in parent table miusernames.
I need help in alter table miemailids as adding foreign key relationship for column UserNamesID with parent table miusernames.. Help me with the query to alter table..I feel good if i get exact query.. thanx in advance