According to http://download-uk.oracle.com/docs/cd/B19306_01/server.102/b14200/functions208.htm
or http://download-uk.oracle.com/docs/cd/B19306_01/server.102/b14200/functions165.htm#i1038176
there are at least some parameters you canniot use in distributed transactions.
If you look in GV$FIXED_VIEW_DEFINITION how V$VERSION is created you
can see that it references USERENV('Instance')
SQL> select * from GV$FIXED_VIEW_DEFINITION
2 where VIEW_NAME = 'V$VERSION'
3 /
INST_ID VIEW_NAME
---------- ------------------------------
VIEW_DEFINITION
--------------------------------------------------------------------------
1 V$VERSION
select BANNER from GV$VERSION where inst_id = USERENV('Instance')
So I suspect that 'Instance' also cannot be used in distributed
transactions although it isn't written there. See also example below
(keep in mind that db link is created back to my user and I'm actually
referencing the same table):
SQL> create table q as select * from v$version;
Table created.
Elapsed: 00:00:00.01
SQL> create database link dlink connect to gints identified by gints
using 'fedora';
Database link created.
Elapsed: 00:00:00.00
SQL> desc q@(protected)
Name Null? Type
----------------------------------------- -------- ----------------------------
BANNER VARCHAR2(64)
SQL> select * from q;
BANNER
----------------------------------------------------------------
Oracle9i Enterprise Edition Release 9.2.0.4.0 - Production
PL/SQL Release 9.2.0.4.0 - Production
CORE 9.2.0.3.0 Production
TNS for Linux: Version 9.2.0.4.0 - Production
NLSRTL Version 9.2.0.4.0 - Production
Elapsed: 00:00:00.00
SQL> insert into q select * from v$version;
5 rows created.
Elapsed: 00:00:00.00
SQL> insert into q@(protected);
insert into q@(protected)
*
ERROR at line 1:
ORA-02070: database DLINK does not support operator USERENV in this context
Elapsed: 00:00:00.01
SQL>
Gints Plivna
http://www.gplivna.eu
2006/12/5, Jeffrey Beckstrom <JBECKSTROM@(protected)>:
>
> I create some tables similar to their v$ version which I want to populate.
> Here is one example - any idea why I am getting the error.
>
> SQL> l
> 1 INSERT into rta.lms_V$VERSION@(protected)
> 2 ( banner
> 3 )
> 4 SELECT
> 5 banner
> 6* from V$VERSION
> SQL> /
> SELECT
> *
> ERROR at line 4:
>
ORA-02070: database EMGR does not support operator USERENV in this context
>
>
> SQL>
>
> Jeffrey Beckstrom
> Database Administrator
> Greater Cleveland Regional Transit Authority
> 1240 W. 6th Street
> Cleveland, Ohio 44113
--
http://www.freelists.org/webpage/oracle-l