Home » Developer & Programmer » Precompilers, OCI & OCCI » error LNK2019: unresolved external symbol _sqlcxt  () 1 Vote
error LNK2019: unresolved external symbol _sqlcxt [message #284626] Fri, 30 November 2007 05:50 Go to next message
ijy_david
Messages: 7
Registered: August 2007
Location: UK
Junior Member
Hi,

I am trying to build a library file on windows and am having Oracle 9 and 10 installed here.
But I am getting the error
error LNK2019: unresolved external symbol _sqlcxt referenced in function.

I had seen a solution as to include orasql9.lib/orasql10.b in the LIB path. But this is not helping me.
I am using a makefile also.

Can anybody pls help me on this regard? Is there any other workaround?

My proc file was compiled to c file on unix platform. Is that the problem?

Cheers,
Ijy
Re: error LNK2019: unresolved external symbol _sqlcxt [message #284633 is a reply to message #284626] Fri, 30 November 2007 06:17 Go to previous messageGo to next message
Michel Cadot
Messages: 68625
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Did you say you are trying to use on Windows object files that are compiled on Unix?
If this is the case, the answer is: of course it could not work.

Regards
Michel
Re: error LNK2019: unresolved external symbol _sqlcxt [message #284882 is a reply to message #284633] Sun, 02 December 2007 08:25 Go to previous messageGo to next message
vicenzo
Messages: 28
Registered: December 2007
Location: Paris
Junior Member
You've got an linker error apparently generated by microsoft linker.

_sqlcxt is always defined in orasqlX.lib where X is Oracle version.

Your linker just doesn't find it ! So, it's just a path or env variable problem.

Can you post your makefile ?

Re: error LNK2019: unresolved external symbol _sqlcxt [message #284917 is a reply to message #284633] Sun, 02 December 2007 21:06 Go to previous messageGo to next message
ijy_david
Messages: 7
Registered: August 2007
Location: UK
Junior Member
Thanks for all your replies.

Michel,

I am getting the error when I am trying to compile a c file which has Pro*C code. The pro*c file was compiled on Unix to get the c file. The c file is being compiled on Windows to get the library file.
Is this the problem?

Vicenzo,

Inspite of setting the path for orasqx10.lib and oasql10.lib in the env variable, am facing the problm.

Looking forward for any assistance on this.

Cheers,
Ijy
Re: error LNK2019: unresolved external symbol _sqlcxt [message #284918 is a reply to message #284917] Sun, 02 December 2007 21:37 Go to previous messageGo to next message
ijy_david
Messages: 7
Registered: August 2007
Location: UK
Junior Member
Hi,

I have somthing to add with this also.
I had come across similar problem in Unix also.
The problem was resolved when 32-bit library was used for compilation. But I am not able to find anything such related when doing in windows.

cheers,
ijy
Re: error LNK2019: unresolved external symbol _sqlcxt [message #284934 is a reply to message #284918] Sun, 02 December 2007 23:15 Go to previous messageGo to next message
Michel Cadot
Messages: 68625
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
The Pro*C parameter (default or available) values depend on the OS.
Either you know the correct values for the target OS, either you precompile in this OS.
The latter is the far preferred way to do it.

Regards
Michel
Re: error LNK2019: unresolved external symbol _sqlcxt [message #285060 is a reply to message #284934] Mon, 03 December 2007 04:20 Go to previous messageGo to next message
vicenzo
Messages: 28
Registered: December 2007
Location: Paris
Junior Member
Can you post your makefile to see if there is anything wrong with it ?

[Updated on: Mon, 03 December 2007 04:20]

Report message to a moderator

Re: error LNK2019: unresolved external symbol _sqlcxt [message #285665 is a reply to message #285060] Wed, 05 December 2007 04:43 Go to previous messageGo to next message
ijy_david
Messages: 7
Registered: August 2007
Location: UK
Junior Member
Hi Michel,

Compiled the pro*c code from windows. and still am getting the same error.
So it is not the problem with unix compilation of pro*c file i presume.

and vicenzo,
am sorry am unable 2 post the makefile, wat exactly are you trying to look into tht. I can help on that.
in the lib path i am specifying the path to orasql10.lib and tried even orasql9.lib. But doesnt help.

could anybody help on this pls?

cheers,
ijy
Re: error LNK2019: unresolved external symbol _sqlcxt [message #285759 is a reply to message #285665] Wed, 05 December 2007 08:41 Go to previous message
vicenzo
Messages: 28
Registered: December 2007
Location: Paris
Junior Member
You problem is a linking problem and not compilation problem.

The linker is not able to find the symbol, it means it doesn't find the oracle sqllib that contains the symbol...

The only way to help you is to look at the linker command line and options...

Without the makefile ou even the linking part of the makefile, we cannot help you !

Previous Topic: warning message on .pc to .c file conversion
Next Topic: Changing the value of SQLCA run time
Goto Forum:
  


Current Time: Thu Mar 28 18:10:38 CDT 2024