Stored procedure
-
Hi friends!!! I have a table where i have a set of tutor ids and the relevant points they get according to a student. table is like student_name // tutor1_id // points // tutor2_id // points .... john // 101 // 4 // 102 // 5 jacob // 102 // 3 // 105 // 4 and another table tutor_id // tutor_name 101 ron 102 reid 103 abc ... I need to show the points the tutor name and the student name together with a join among the two tables.. Right now i am using union operator for getting all the records Is there any other method how i can get all the details together Thanks for your time...
I was born dumb!! :laugh:Programming made me laugh:laugh:!!! --sid--
-
Hi friends!!! I have a table where i have a set of tutor ids and the relevant points they get according to a student. table is like student_name // tutor1_id // points // tutor2_id // points .... john // 101 // 4 // 102 // 5 jacob // 102 // 3 // 105 // 4 and another table tutor_id // tutor_name 101 ron 102 reid 103 abc ... I need to show the points the tutor name and the student name together with a join among the two tables.. Right now i am using union operator for getting all the records Is there any other method how i can get all the details together Thanks for your time...
I was born dumb!! :laugh:Programming made me laugh:laugh:!!! --sid--
hi try this query select t1.student_name,t2.tutor_name ,t1.points from table1 t1,table2 t2 where t1.tutor1_id=t2.tutor_id ...... but i think u should not maintain the table1 like this (as u did) try this way... studentname//tutor//points john // 101 // 4 john// 102 // 5 and so on if u feel its voilating normalization then split it into two tables. happy coding:)
-
Hi friends!!! I have a table where i have a set of tutor ids and the relevant points they get according to a student. table is like student_name // tutor1_id // points // tutor2_id // points .... john // 101 // 4 // 102 // 5 jacob // 102 // 3 // 105 // 4 and another table tutor_id // tutor_name 101 ron 102 reid 103 abc ... I need to show the points the tutor name and the student name together with a join among the two tables.. Right now i am using union operator for getting all the records Is there any other method how i can get all the details together Thanks for your time...
I was born dumb!! :laugh:Programming made me laugh:laugh:!!! --sid--
Hi, Can u please tell me what is the exact output u require. Also can u please provide me with the table structure of the first table student_name // tutor1_id // points // tutor2_id // points ... what does this ... indicate
Thanking you in Advance Regards Pratik Shah