SQL INNER JOIN
-
I want to change following sql statement to using inner join but I dont know how to join on two column on the two table. Thanks for helping. select * from Persons A, Banks B where B.Student_ID = A.Student_ID AND B.class_NO = A.claa_NO when I change to the following statement, I get an error on the syntax. Incorrect syntax near the keyword 'ON'. select * from Persons A INNER JOIN B ON B.Student_ID = A.Student_ID ON B.class_NO = A.claa_NO Please kindly help. Thanks
-
I want to change following sql statement to using inner join but I dont know how to join on two column on the two table. Thanks for helping. select * from Persons A, Banks B where B.Student_ID = A.Student_ID AND B.class_NO = A.claa_NO when I change to the following statement, I get an error on the syntax. Incorrect syntax near the keyword 'ON'. select * from Persons A INNER JOIN B ON B.Student_ID = A.Student_ID ON B.class_NO = A.claa_NO Please kindly help. Thanks
Try SELECT * FROM PERSONS A INNER JOIN BANK B ON B.STUDENT_ID = A.STUDENT_ID AND B.CLASS_NO = A.CLASS_NO
-
Try SELECT * FROM PERSONS A INNER JOIN BANK B ON B.STUDENT_ID = A.STUDENT_ID AND B.CLASS_NO = A.CLASS_NO
-
I want to change following sql statement to using inner join but I dont know how to join on two column on the two table. Thanks for helping. select * from Persons A, Banks B where B.Student_ID = A.Student_ID AND B.class_NO = A.claa_NO when I change to the following statement, I get an error on the syntax. Incorrect syntax near the keyword 'ON'. select * from Persons A INNER JOIN B ON B.Student_ID = A.Student_ID ON B.class_NO = A.claa_NO Please kindly help. Thanks