一个累加的小问题
我有一张表TB,比方说有三个字段:AA,BB,CC
AA BB CC
内容为 a1 b1 c1
b2 c2
c3
我如何才能求出AA+BB+CC的所有组合的内容,也就是a1b1c1,a1b1c2,a1b1c3,a1b2c1,a1b2c2,a1b2c3
用VB我已经解决了,用下面的SQL:
select AA + BB + CC from (select AA from TB) as T1,(select BB from TB) as T2,(select CC from TB) as T3 where AA <> "" and BB <> "" and CC <> ""
VFP中通不过,说是语法错误,高手帮忙啊!
先谢谢啦...