|
The premise is that ypid and zlid cannot be repeated, and the char type can be used, with characters in front of it to distinguish, such as: yp00001, zl00001
select c. time, c. medical treatment number, a.ypname as cost
from c,a
where c. Expense classification = a.ypid
To
union
select c. time, c. medical number, b. zlname as cost
from c,b
where c. Expense classification = b.zlid |
|