I have the following tables:
TeamMemberInformation which has the following fields (MemberId, Name) and contains the following rows
MemberId Row
0 Name
1 Email
2 Phone
I also have a second table (User) which contains the following fields(UserId, Name, Email, Phone, etc) and contains the following rows:
userId Name Email Phone
0 Eric e@mail.com 555-1221
1 Steve s@mail.com 555-1345
2 bob b@mail.com 555-2314
3 lisa l@mail.com 555-2222
Given these two tables, I would like to generate the following resultset for a given user
TeamMemberInformation:Row User:
Name Eric
Email e@mail.com
Phone 555-1212
What I'm trying to do is bind some of the user table columns to the appropriate rows in the TeamMember Information table to generate the resultset above which I can then bind to a grid. Being a novice to sql, I can't seem to figure out how to do this. Maybe there is a better way to do this, I just don't know how. Basically, the columns become rows in the resultset. Any recommendations or thoughts? By the way, is there a name for doing this?