挺难的SQL,连工作十几年的老程序员都没有办法。
Oer 2003-10-20 07:07:08 有一机子(SG1)上有一个数据库(SGLC)中有表(Tab_lc)字段(no,sfys,jld)
有一机子(SG2)上有一个数据库(SGJL)中有表(Tab_jl)字段(no,sfys,jld,date,fhdw)
Tab_lc
no sfys jld
1 y 1#
2 y 2#
3 Y 2#
2 Y 1#
3 Y 1#
Tab_jl
no sfys jld date fhdw
1 null 1# 2003-10 aa
2 null 2# 2003-10 bb
3 null 2# 2003-11 bb
2 null 1# 2003-11 cc
我想得到的结果是:select * from tab_jl,sglc..tab_lc where tab_jl.no=sglc..tab_lc.no and sglc..tab_lc.sfys='y' and tab_Jl.jld=sglc..tab_lc.jld
但是这是要在同一始机子上。但我现在是在不同的机子了?