oracle 在同一条SQL中不能使用多个dblink,该如何解决

如题!

ORA-02019 connection description for remote database not found Cause: An attempt was made to connect or log in to a remote database using a connection description that could not be found. Action: Specify an existing database link. Query the data dictionary to see all existing database links. See your operating system-specific Net8 documentation for valid connection descriptors. 检查所用到DBLINK名是否已经定义
第一:数据库多链是肯定允许的。你要检查DBLINK名的存在与否性。第二:编程方式不好,INSERT INTO TAB A 时最好把 A的要插入的字段名加上。若哪天A表加了一个字段,扩展了一下,这SQL就要报错了。
温馨提示:答案为网友推荐,仅供参考
第1个回答  2013-07-11
把这条语句拆分
第2个回答  2013-07-11
没这样用过,现在没手里也没环境测试。要是真没办法这样直接用,写个过程吧。先把查询的结果放变量里面,然后在插入。就是上面那个老大说的拆分试试。
相似回答