Your question is confusing, in the initial post you are trying an insert, but in the edit you said this: "For each Aid in T1 I have to find the corresponding value of Gid (eg UQid1) in T2 and copy the (strictly) non-zero value of R in that row in T2 into the corresponding row in T1."
If the latter is truly the case, you should be able to do something like this:
UPDATE table_1 AS t1 SET t1.value = (SELECT t2.value FROM table_2 AS t2 WHERE t2.UQid1 = t1.id);