Click here to Skip to main content
15,880,279 members
Please Sign up or sign in to vote.
4.00/5 (1 vote)
See more:
T1 SID SN
1 Goa
2 Punjab
3 J&K

T2
TID TN
11 A
22 B
33 C

T3
ID SID TID TV
111 1 11 10
222 2 22 20
333 3 33 30

TV rowwise,TN rowwise,SN in column
Above are 3 tables .Data to show in grid view as below
SN A(TN) B(TN) C(TN)
Goa(SN) 410 10(TV) 30
Punjab 80(TV) 20(TV)
Posted
Comments
khurram ali lashari 11-Feb-14 14:35pm    
Please Improve Your Question...And Show us What you have Tried ?....

1 solution

Well Do Something like this..........
This is the Sql query
SQL
 SELECT        SN,TN
FROM            T1 INNER JOIN
                         T3 ON T1.SID = T3.SID INNER JOIN
                         T2 ON T3.TID = T2.TID
where SID=1
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900