SQL code:
select a.transactionid, a.creator, a.creattime, a.updatetime,
a.status, a.handletimes, a.operatetype, a.objecttype,
a.objectid, a.objectname, a.objecturl, a.nettype,
a.netid, a.returntime, a.returncode, a.returndesc, a.netstatus,b.netname
from t_cms_transaction a,
( select distinct netid, nettype, contenttype, netname from t_cms_netconf ) b
where a.netid = b.netid
and a.nettype = b.nettype
and a.objecttype = b.contenttype || v_sql
order by 1
v_sql: °üº¬¶à¸ö²éѯ×ֶεĶ¯Ì¬sql¡£¹Ê²»ºÃÔÚÏà¹Ø×ֶν¨Ë÷Òý£¡
a±íÊý¾ÝÁ¿£º1000W
b±íÊý¾ÝÁ¿: 500
ÒÔÉÏsqlÖ´ÐÐÒ»±éÒª30·ÖÖÓ£¬Çë´ó¼Ò°ïæÓÅ»¯Ï£¡Ð»Ð»£¡ÔÚÏߵȣ¡
ʹÓÃuse_hash(a b)hintÌáʾЧ¹ûÒ²²»Ã÷ÏÔ£¡
²»ÅÅÐò»á¿ìºÜ¶àµÎ˵¡£¹þ£¬´¿Êô°ï¶¥ = =£¡
bΪʲôҪµ¥¶À×ö³ÉÒ»¸öÐé±í?
ÒýÓà SQL code select a.transactionid, a.creator, a.creattime, a.updatetime, a.status, a.handletimes, a.operatetype, a.objecttype, a.objectid, a.objectname, a.objecturl, a.nettype, ¡¡|| v_sql ÊDz»ÊǸúµÄ¶¼ÊÇһЩÌõ¼þ£¿£¿
Èç¹ûÊÇһЩÌõ¼þµÄ»°¿ÉÒÔÏÈ¿¼ÂÇ
with tem as (
select a.transactionid, a.creator, a.creattime, a.updatetime,