Sitemap

Amicuk Programming Answers

ORA-06521:PL/SQL:Error mapping function :ORA-06522:undefined :ODCIAggregate

2015-10-11   Views:8

Advertisement

Hi, I am getting the following error : SQL> select MinDistance(TT) from egg1; select MinDistance(TT) from egg1 ERROR at line 1: ORA-06521: PL/SQL: Error mapping function ORA-06522: /usr/lib/oracle/xe/app/oracle/product/10.2.0/server/lib/custagg.so: u

Hi,
I am getting the following error :
SQL> select MinDistance(TT) from egg1;
select MinDistance(TT) from egg1
ERROR at line 1:
ORA-06521: PL/SQL: Error mapping function
ORA-06522: /usr/lib/oracle/xe/app/oracle/product/10.2.0/server/lib/custagg.so:
undefined symbol: ODCIAggregateInitialize
I am compiling my C program with OCI using the following command :
g++ -Wall -c custagg.c -o custagg.o -I$ORACLE_HOME/rdbms/public -I/usr/lib
I am linking to get a shared library custagg.so file with following command :
ld -shared -o custagg.so custagg.o $ORACLE_HOME/lib/l*.so ../../usr/lib/libstdc++.s*
I am not getting any errors during these two phases.
And when i am calling the extproc custagg(Mindistance) which i implemented using ODCI(oracle data catridge interface) ...I am getting the error undefined symbol : ODCIAggregateInitialize
So can any one please let me know what shared libraries are required to access the ODCI services and also am I compiling and linking it the right way or am I missing any libraries.
I have the oci.h & odci.h and several other header files in my :
$ORACLE_HOME/rdbms/public
And while linking i am using : $ORACLE_HOME/lib/*.so files.
So I don't know whether my directory is missing some shared files related to ODCI : can any one please let me know which files or shared libraries I am missing :
Below are list of files in my : $ORACLE_HOME/lib :
custagg123.o libclntsh.so libdbcfg10.so libjox10.so libocci.so.10.1 liborasdkbase.so libskgxpd.so libunwind.so.5
custagg.so libclntsh.so.10.1 libemmas10.so libldapjclnt10.so libocijdbc10.so liborasdkbase.so.10.2 libskgxpu.so libxdb.so
facility.lis libclsra10.so libhasgen10.so libnjni10.so libocr10.so liborasdk.so libsqlplus.so shell.so
hsdb_odbc.so libcorejava.so libheteroxa10.so libnjssl10.so libocrb10.so liborasdk.so.10.2 libsqora.so.10.1 sysliblist
hsdb_ora.so libcoresh10.so libhsbase.so libnnz10.so libocrutl10.so libqsmashr.so libsrvm10.so
lclasses12.zip libcprts.so.5 libhsnav.so libnque10.so libodm10.so libskgxn2.so libsrvmhas10.so
libagtsh.so libcxa.so.3 libimf.so libntcpaio10.so libodmd10.so libskgxns.so libsrvmocr10.so
libagtsh.so.1.0 libcxa.so.5 libirc.a libocci.so libons.so libskgxp10.so libuini10.so
Please reply to my queries.
Please let me know if you want to have a look at the symbols of my object file
Thanks & Regards,
-NN

The replay answer
Advertisement
It's only a quick guess but have you checked your tnsnames.ora file to ensure you've opened the environment to find the libraries? If you set the EXTPROC_DLLS=ANY, you open the database to security issues but it should tell you if this cause because you can't access the library that contains the symbol.
SID_LIST_CALLOUT_LISTENER =
(SID_LIST =
(SID_DESC =
(SID_NAME = PLSExtProc)
(ORACLE_HOME = <oracle_home_directory>)
(PROGRAM = extproc)
(ENV = "EXTPROC_DLLS=ONLY:
<oracle_home_directory>/customlib/writestr1.so
,LD_LIBRARY_PATH=<oracle_home_directory>/lib")
)

Go to See the other 2 answers

ORA-06521: PL/SQL: Error mapping function

Category:DefaultRelease time:2015-10-11Views:130

Hi folks, I am trying to run gather_table_stats for a particular table but am getting the below error. Any ideas? SQL> execute DBMS_STATS.gather_table_stats( ownname=>'DBO',tabname=>'CD_JOURNAL_CHANGE_REG',method_opt=>'FOR ALL INDEXED COLUMNS'[More]

ORA-06521: PL/SQL: Error mapping function with 10.1.0 external procedure

Category:DefaultRelease time:2015-10-11Views:130

We have an external procedure running fine on 8.1.7 on VMS. After compiling and linking succesfully under 10.1.0, I get ORA-06521 PL/SQL: Error mapping function and ORA-06522: ERROR - vms_dlsym for file x, where x in the filename of the linked execut[More]

ORA-06521: PL/SQL: Error mapping function :ORA-06522:undefined :ODCIAggre

Category:DefaultRelease time:2015-10-11Views:130

Hi, I am getting the following error : SQL> select MinDistance(TT) from egg1; select MinDistance(TT) from egg1 ERROR at line 1: ORA-06521: PL/SQL: Error mapping function ORA-06522: /usr/lib/oracle/xe/app/oracle/product/10.2.0/server/lib/custagg.so: u[More]

ORA-06521:PL/SQL:Error mapping function :ORA-06522:undefined :ODCIAggregate

Category:DefaultRelease time:2015-10-11Views:130

Hi, I am getting the following error : SQL> select MinDistance(TT) from egg1; select MinDistance(TT) from egg1 ERROR at line 1: ORA-06521: PL/SQL: Error mapping function ORA-06522: /usr/lib/oracle/xe/app/oracle/product/10.2.0/server/lib/custagg.so: u[More]

ORA-06521: PL/SQL: Error mapping function while writting into a text file

Category:DefaultRelease time:2015-10-11Views:130

Hi, I'm getting an errror ORA-06521: PL/SQL: Error mapping function while trying to write data into a text file. I'm using the following code: --To create a new directory create or replace directory temp as 'C:/temp'; declare                 l_str va[More]

Call to ldap server fails ORA-06521: PL/SQL: Error mapping function

Category:DefaultRelease time:2015-10-11Views:130

I am getting this error(s) ORA-06521: PL/SQL: Error mapping function ORA-06512: at "SYS.DBMS_LDAP_API_FFI", line 0 ORA-06512: at "SYS.DBMS_LDAP", line 1338 ORA-06512: at "SYS.DBMS_LDAP", line 1273 ORA-06512: at "SYS.DBMS[More]

Ldap problem, ORA-06521: PL/SQL: Error mapping function

Category:DefaultRelease time:2015-10-11Views:130

I am getting this error(s) ORA-06521: PL/SQL: Error mapping function ORA-06512: at "SYS.DBMS_LDAP_API_FFI", line 0 ORA-06512: at "SYS.DBMS_LDAP", line 1338 ORA-06512: at "SYS.DBMS_LDAP", line 1273 ORA-06512: at "SYS.DBMS[More]

DBMS_LDAP call fails with ORA-06512 Error Mapping function

Category:DefaultRelease time:-0001-11-30Views:130

Hi, I am facing a problem with workflow integration with LDAP. I receive ORA-6512 Error Mapping Function on one particular line within the WF_LDAP.get_cfg_val procedure. WHILE my_entry IS NOT NULL LOOP my_vals := DBMS_LDAP.get_values (p_session, my_e[More]

ERROR MAPPING FUNCTION

Category:DefaultRelease time:-0001-11-30Views:130

Hi All, I've created a library and mapped it to the operating system directory(UNIX/AIX), and created a procedure that calls my C program through pl/sql, but I keep getting error message (06521)Error mapping function. I have void datatype return valu[More]

ORA-06522 - undefined symbol

Category:DefaultRelease time:-0001-11-30Views:130

I'm getting the following error when i execute external procedure: ORA-06520: PL/SQL: Error loading external library ORA-06522: /oracle/ora10/mm_server/libhello.so: undefined symbol: NfmIsRegistered ORA-06512: at "AOL.VERIFICATION", line 1 ORA-0[More]

Error mapping function in external procedure call

Category:DefaultRelease time:-0001-11-30Views:130

I'm trying to create an external procedure in PL/SQL8.1 to run an operating system command from within a PL/SQL block. The C function couldn't be simpler: extern void host_command(char *command) (void)system(command); It's even ignoring the return va[More]

Hot
Hi all. Until recently my home network consisted of an ISP-supplier Thomson TG585 wireless router supporting both a MacBook Pro & iMac. The config. worked to a point. Both machines could get to the web fine, but frustratingly would rarely "see&qu [More]
Hi all, I am trying to install the RUP3 patch on Windows 2003 server. I am getting the following error when installing patch 6272715 which is required to be installed before installing patch 6141000. If i continue installing patch 6141000 after ignor [More]
I was wondering about buying a Mp3-Player a long time, and finally decided that Zen Mikro would be the best choice to make. There is no information about the kind of headphones who are included in the package, and knowing the quality of the Headphone [More]
Hello everybody, I am using the struts,jsp and spring framework. In my application there are 100s of rows i have to insert into the database 1 by 1. I am using usertransaction all other things are working right but i am not getting the real time perf [More]
I'm trying to use flexUnit, but I'm running into a problem. When I go to executeFlexUnit Tests, I encounter the compiler error: "Content is not allowed in prolog" The FlexUnitApplication.mxml file that gets generated looks like this: <!-- Thi [More]
Can you help that how can i connect  Ipad 1 with ios 5.1.1 to apple tv 3 ?! I used airplay but it cant ?!Welcome to the Apple Community. The iPad 1 doesn't support AirPlay Mirroring, but you should still be able to use Basic AirPlay Basic AirPlay: As [More]
What is a good way to monitor these queues, if something is getting stuck, processing for too long.Hi John, Thanks for the response. I understand that these are just transcation code. These transaction codes displays the current status of the queue a [More]
Hi Everyone, My requirement is to play videos stored in KM folders. When clicked on any video it gives the option to open and save and in either case it takes lot of time to play the video on portal. Is their any way to reduce the time taken for play [More]
I've downloaded the distribution license version of Flash Player 11.5.502.135.  In checking the version of the file after downloading it seems to be Flash Player 11.5.502.110.  Is the version wrong on the file, or is the file the wrong version?Let me [More]
I want to change the name of my iPhoto library from 'Samsung HDD' (in the picture) to other name. I'm going to change it via Finder -- by using Get Info and rename it, is this the right method? And will this affect my photos? Thanks in advances.no - [More]