类似1楼代码: Adodc1.RecordSource = "select cs.js_dm,cs.备件代码,cs.备件名称,cs.备件规格,cs.进口计算机号,cs.最低库存量,sl.结存数量,sl.结存金额,sl.结存单价,sl.类别代码 from JWCK_BM as cs,jwl_jiec as sl" & _ " where cs.备件代码 = sl.备件代码" & " and sl.类别代码='" & Text2 & "' order by cs.备件代码"
way1 :select * from a union all select * from b way2 :select * from a,b where a.columna=b.columna
select * from a union all select * from b
Adodc1.RecordSource ="select * from a,b where a.id=b.id"
Adodc1.RecordSource = "select cs.js_dm,cs.备件代码,cs.备件名称,cs.备件规格,cs.进口计算机号,cs.最低库存量,sl.结存数量,sl.结存金额,sl.结存单价,sl.类别代码 from JWCK_BM as cs,jwl_jiec as sl" & _
" where cs.备件代码 = sl.备件代码" & " and sl.类别代码='" & Text2 & "' order by cs.备件代码"
way2 :select * from a,b where a.columna=b.columna
union all
select * from b