I have 2 tables table1 and table2:
- table1 contains a field named
idwith a value1212(example) in it. - table2 has a field named
actionwith a data likeadded 1212orupdated 1212.
Now check this query.
SELECT t1.*, t2.name
FROM table1 t1, table2 t2
WHERE t2.action LIKE 'added t1.id'
I want to add the name field in the second table, to first one with the added(updated not needed) data only.
What is the where clause for this condition?
How can I query this?
I did it like this.
thanks to all who tried to help me.