Hi,

I have 3 tbls

Student : StdID,Name

Score : Name, Subject, Score

Summry : StdID,Name, Score, Subject

suspose each fields and each tbl has so many records.

I want to insert into tblSummary which depends on...
- I need to loop until score is end of that fileds then insert StdID
to summary

- I mean StdID in Summary must also have every subject
of tblScore.

This is my coding (unsucceeded)

Do While Not rsScore.EOF
Do While Not rsStd.EOF
wp = rsStd.Fields!StdID

comtxt = "Insert Into tblSummry (StdID,Name)" & _
"Values('" & wp & "','" & rsScore.Fields!name & "')"

upCom.ActiveConnection = cn
upCom.CommandType = adCmdText
upCom.CommandText = comtxt
upCom.Execute
rsStd.MoveNext
Loop
rsScore.MoveNext

Loop


can anyone help me?
thanks!