is_common_adj = loadTable("dfs://pit_stock_ts", "is_common_adj") is_common_ori = loadTable("dfs://pit_stock_ts", "is_common_ori") // select * from is_common_ori where code='000677.SZ' and report_period=2009.12.31 // select * from is_common_ori where report_period=2009.12.31 m_nDate = take(2011.10.01, 3); report_period = [2008.12.31, 2009.12.31, 2010.12.31] //code = `000001.SZ`000677.SZ`600001.SH; tbl_query = table(report_period, m_nDate); tbl_query_exp = select code, report_period, m_nDate from ej(is_common_ori, tbl_query, `report_period) where partition(code, 0); is_common_ori_part = select * from ej(is_common_ori, tbl_query, `report_period) where partition(code, 0); is_common_ori_part select top 100 * from aj(tbl_query_exp, is_common_ori_part, `code`report_period`m_nDate, `code`report_period`appear_at_date);