I have table a and b, each have an average field in them. Data is inserted into only one of the tables at a time so either of the average fields can remain null at one given time. How can i retrieve the value in either of the fields in the two tables which is not null
Table a
id average labref
1 325 123
Table b
id average labref
2 null 123
If table a is the one with the average value, i pick that value and if next time table b is the a with the average value and table one is average is null, i pick the value of table a. They both have same id used called labref!
OR