【发布时间】:2009-04-14 12:49:58
【问题描述】:
我有一个非常大的查询,格式如下:
select ...
from ( select field1,
field2
from some_table ) table1,
( select field1,
field3
from other_table ) table2
where .....
我是否可以在 from 子句中的其他表定义之一中引用 from 子句中“定义”的表之一,比如说 table1?
例如:
select ....
from ( select field1,
field2
from some_table ) table1,
( select table1.field1,
field3
from other_table,
table1 ) table2
where .....
免责声明:我想做的并不像上面的例子那么简单。这个例子只是为了说明这个想法。
【问题讨论】:
-
这并不是您问题的真正答案,但您的问题涉及的一些问题可能可以通过使用视图来解决。