i have table like below
table_a
sno name student_id
1 abcd 1
2 bcad 2
table_b
sno student_id amount
1 1 600
2 1 500
3 2 200
compare twotables addition amount field and select name field
i want like below format
Student_id name totalamount
1 abcd 1100
2 bcad 700