Home » SQL & PL/SQL » SQL & PL/SQL » PL/SQL wrapper error
PL/SQL wrapper error [message #222725] Tue, 06 March 2007 03:17 Go to next message
subratd
Messages: 12
Registered: March 2007
Junior Member
Hi,
I want to know how the wrap utility of oracle9i works. For this i wrote a small procedure and called the wrap utility from cmd.
But running it gave the following error:


D:\oracle\ora92\bin>wrap iname=C:\Test.sql
WARNING: OCI init failed with code -1
PL/SQL Wrapper error: Couldn't initialize OCI.

Can any one please help me solving this.
Re: PL/SQL wrapper error [message #222763 is a reply to message #222725] Tue, 06 March 2007 05:48 Go to previous messageGo to next message
bhupinderbs
Messages: 67
Registered: July 2006
Location: Bangalore
Member
Hi
Check in the attachment. Whether you are following the same.
It is working in my case.

Bhupinder Singh
  • Attachment: wrap.jpg
    (Size: 36.57KB, Downloaded 2236 times)
Re: PL/SQL wrapper error [message #222771 is a reply to message #222725] Tue, 06 March 2007 05:58 Go to previous messageGo to next message
tahpush
Messages: 961
Registered: August 2006
Location: Stockholm/Sweden
Senior Member

Is ORACLE_HOME correct ?

[Updated on: Tue, 06 March 2007 06:03]

Report message to a moderator

Re: PL/SQL wrapper error [message #222797 is a reply to message #222763] Tue, 06 March 2007 07:29 Go to previous messageGo to next message
subratd
Messages: 12
Registered: March 2007
Junior Member
Ya, im issuing the same commands. But its giving me the following error all the time.

D:\oracle\ora92\bin>wrap iname=C:\Test.sql oname=C:\tbs.plb
WARNING: OCI init failed with code -1
PL/SQL Wrapper error: Couldn't initialize OCI.

FYI, im using Oracle client. Since in my version of client, there was no wrap.exe, i got it from a different system and put it in my bin.The required dlls also i got from another system and put in bin.

I feel something is wrong while calling OCI.
Re: PL/SQL wrapper error [message #222804 is a reply to message #222797] Tue, 06 March 2007 07:51 Go to previous messageGo to next message
Frank
Messages: 7901
Registered: March 2000
Senior Member
Why don't you say so in your original post?
You just made up an installation and now you wonder why it doesn't work...
Re: PL/SQL wrapper error [message #222807 is a reply to message #222804] Tue, 06 March 2007 07:56 Go to previous messageGo to next message
subratd
Messages: 12
Registered: March 2007
Junior Member
Ya, i made up the installation. But the same was suggested in one of the site. They too took the exe and dlls from a different source and it worked for them.
Anywe, is there any alternative way to get it done.
Since i use the oracle client which is licensed , i cant go for installing another version of oracle client. This is the only one i can use.And this version deosnt have wrap.exe and related dlls in it.
Re: PL/SQL wrapper error [message #222817 is a reply to message #222807] Tue, 06 March 2007 08:58 Go to previous messageGo to next message
JRowbottom
Messages: 5933
Registered: June 2006
Location: Sunny North Yorkshire, ho...
Senior Member
I think that's sort of the point of licensing - to restrict what you've got access to to what you paid for.

Regardless, Wrap.exe should be available on your server in the %oracle_home%/bin directory (if you're on windows)
Re: PL/SQL wrapper error [message #250574 is a reply to message #222725] Tue, 10 July 2007 09:11 Go to previous messageGo to next message
alinn
Messages: 1
Registered: July 2007
Junior Member
Perhaps that's the point of licensing, but if you want to be able to wrap on a machine (maybe an automated build server) without installing the huge Oracle client it would be nice if Oracle provided a standalone wrap capability that could just be dropped on that machine and work (many others do this, including InstallShield, Microsoft, etc.).

Anyway, this worked for me:

1. Create a directory on your machine to serve as your ORACLE_HOME (e.g. C:\OHOME).

2. Copy these files to a directory on your ORACLE_HOME from a machine with WRAP properly installed:

%ORACLE_HOME%\bin\oraclient9.dll
%ORACLE_HOME%\bin\oracommon9.dll
%ORACLE_HOME%\bin\ORACORE9.DLL
%ORACLE_HOME%\bin\orageneric9.dll
%ORACLE_HOME%\bin\oraldapclnt9.dll
%ORACLE_HOME%\bin\oran9.dll
%ORACLE_HOME%\bin\ORANCDS9.DLL
%ORACLE_HOME%\bin\orancrypt9.dll
%ORACLE_HOME%\bin\oranhost9.dll
%ORACLE_HOME%\bin\oranl9.dll
%ORACLE_HOME%\bin\oranldap9.dll
%ORACLE_HOME%\bin\ORANLS9.DLL
%ORACLE_HOME%\bin\oranms.dll
%ORACLE_HOME%\bin\oranmsp.dll
%ORACLE_HOME%\bin\orannzsbb9.dll
%ORACLE_HOME%\bin\oranoname9.dll
%ORACLE_HOME%\bin\oranro9.dll
%ORACLE_HOME%\bin\orantns9.dll
%ORACLE_HOME%\bin\ORAPLC9.DLL
%ORACLE_HOME%\bin\ORAPLP9.DLL
%ORACLE_HOME%\bin\ORAPLS9.DLL
%ORACLE_HOME%\bin\ORASLAX9.DLL
%ORACLE_HOME%\bin\ORASNLS9.DLL
%ORACLE_HOME%\bin\ORASQL9.DLL
%ORACLE_HOME%\bin\oratrace9.dll
%ORACLE_HOME%\bin\ORAUNLS9.DLL
%ORACLE_HOME%\bin\oravsn9.dll
%ORACLE_HOME%\bin\orawtc9.dll
%ORACLE_HOME%\bin\ORAXML9.DLL
%ORACLE_HOME%\bin\ORAXSD9.DLL
%ORACLE_HOME%\bin\WRAP.EXE
%ORACLE_HOME%\oracore\zoneinfo
%ORACLE_HOME%\oracore\zoneinfo\timezlrg.dat
%ORACLE_HOME%\oracore\zoneinfo\timezone.dat

3. Set your ORACLE_HOME environment variable to your ORACLE_HOME directory.

4. Add %ORACLE_HOME%\bin to your PATH.

5. Wrap on!

The key to get you past the OCI error are copying timezlrg.dat and timezone.dat and setting ORACLE_HOME.

Re: PL/SQL wrapper error [message #250576 is a reply to message #250574] Tue, 10 July 2007 09:13 Go to previous messageGo to next message
Michel Cadot
Messages: 68647
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
I think that 4 months later he either solved his problem or forgot it.

Regards
Michel
Re: PL/SQL wrapper error [message #689328 is a reply to message #222771] Thu, 23 November 2023 03:42 Go to previous message
NevemTeve
Messages: 25
Registered: November 2017
Junior Member
Thank you, in my case setting ORACLE_HOME did help. (It is an AIX 6.1, Oracle 10.2)
Previous Topic: Help with query returning JSON
Next Topic: SQL QUERY
Goto Forum:
  


Current Time: Sat Apr 27 01:32:52 CDT 2024