I have 2 tables..
i will represent the data inn array....
table1 columns are t1_id, t1_value
table2 columns are t2_id, t2_value, t1_id(FK)
table1={{1,data1},{2,data2}};
table2={{1,d1,t1.1},{2,d2,t1.1},{3,d3,t1.2},{4,d4,t1.2}};
i have a query of..
rs = stmt.executeQuery("SELECT t2_value FROM table2 INNER JOIN table1 ON table2.t1_id=(SELECT t1_id FROM table1 WHERE t1_value='my_value');")
I got the right value i needed but instead of just..
d1 d2
what I got is..
d1 d2 d1 d2
please help??
Aucun commentaire:
Enregistrer un commentaire