| BOOK_ID (PK & FK) |
| PRICE_ON_START |
| PRICE_PLUS_COST |
| PRICE_PLUS_EXTRA |
| PRICE_TOTAL |
| BOOK_ID (PK) |
| USER_ID (FK) |
| GROUP |
| PHONE |
| LOCAL_ID |
| USER_ID (PK) |
| NAME |
| SURNAME |
| SEX |
| ISACTIVE |
Hello there,
I have got problem, because I don't know how to get required records.
So, as you can see guys I have three tables, and my question is how to get for particular USER_ID all records from Table1 where GROUP number in second table is for ex == 4.
It means, that for each of the 12 groups I have different values in table1
BOOK_ID in the first and second table is the same number of course.
I'm trying something like that, but this not working :(
var collection1 = from a in table1 from b in table2 where a.book_id == b.book_id && a.user_id == 1 select b
and now I would like to do something like that
var result = from b in table2 from c in collection1 where b.book_id == c.book_id && b.group == 6 select b?
Please help...
Manas MohapatraRank #182 · 13.2K reputationPosted Jul 19, 2015, 9:02 PM EDT
Govinda Rajulu YemineniRank #1,518 · 1K reputationPosted Jul 19, 2015, 10:09 PM EDT
Nickolas Novel4 reputationPosted Jul 20, 2015, 11:15 AM EDT
Manas MohapatraRank #182 · 13.2K reputationPosted Jul 20, 2015, 8:39 PM EDT
Govinda Rajulu YemineniRank #1,518 · 1K reputationPosted Jul 20, 2015, 9:07 PM EDT
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questionsTop experts