dbTalk Databases Forums  

Unresolved external function reference

comp.databases.sybase comp.databases.sybase


Discuss Unresolved external function reference in the comp.databases.sybase forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
ScriptBoy
 
Posts: n/a

Default Unresolved external function reference - 05-06-2004 , 11:27 AM






hi,
I was looking for a C/C++ program that will make a connection to the
sybase server (version 11) and i finally found it at
http://www.cs.sfu.ca/CC/SW/Sybase/DB-LIBRARY/node2.html
now I'm trying to make it work. This program uses sybdb and just
executes dblogin, dbopen, dbcmd, dbsqlexec.
I can compile it but there is some trouble in linking it
Following are the errors when i try to link it:

Turbo Incremental Link 5.00 Copyright (c) 1997, 2000 Borland
Error: Unresolved external 'dbinit' referenced from
C:\SYBASE\SAMPLE\DBLIBRARY\E
XAMPLE3.OBJ
Error: Unresolved external 'dberrhandle' referenced from
C:\SYBASE\SAMPLE\DBLIBR
ARY\EXAMPLE3.OBJ
Error: Unresolved external 'dbmsghandle' referenced from
C:\SYBASE\SAMPLE\DBLIBR
ARY\EXAMPLE3.OBJ
Error: Unresolved external 'dblogin' referenced from
C:\SYBASE\SAMPLE\DBLIBRARY\
EXAMPLE3.OBJ
Error: Unresolved external 'dbsetlname' referenced from
C:\SYBASE\SAMPLE\DBLIBRA
RY\EXAMPLE3.OBJ
Error: Unresolved external 'dbopen' referenced from
C:\SYBASE\SAMPLE\DBLIBRARY\E
XAMPLE3.OBJ
Error: Unresolved external 'dbcmd' referenced from
C:\SYBASE\SAMPLE\DBLIBRARY\EX
AMPLE3.OBJ
Error: Unresolved external 'dbsqlexec' referenced from
C:\SYBASE\SAMPLE\DBLIBRAR
Y\EXAMPLE3.OBJ
Error: Unresolved external 'dbresults' referenced from
C:\SYBASE\SAMPLE\DBLIBRAR
Y\EXAMPLE3.OBJ
Error: Unresolved external 'dbbind' referenced from
C:\SYBASE\SAMPLE\DBLIBRARY\E
XAMPLE3.OBJ
Error: Unresolved external 'dbnextrow' referenced from
C:\SYBASE\SAMPLE\DBLIBRAR
Y\EXAMPLE3.OBJ
Error: Unresolved external 'dbexit' referenced from
C:\SYBASE\SAMPLE\DBLIBRARY\E
XAMPLE3.OBJ
Error: Unresolved external 'dbdead' referenced from
C:\SYBASE\SAMPLE\DBLIBRARY\E
XAMPLE3.OBJ

please help
thanks

Reply With Quote
  #2  
Old   
Michael Peppler
 
Posts: n/a

Default Re: Unresolved external function reference - 05-06-2004 , 01:30 PM






On Thu, 06 May 2004 09:27:10 -0700, ScriptBoy wrote:

Quote:
hi,
I was looking for a C/C++ program that will make a connection to the
sybase server (version 11) and i finally found it at
http://www.cs.sfu.ca/CC/SW/Sybase/DB-LIBRARY/node2.html now I'm trying to
make it work. This program uses sybdb and just executes dblogin, dbopen,
dbcmd, dbsqlexec. I can compile it but there is some trouble in linking it
Following are the errors when i try to link it:

Turbo Incremental Link 5.00 Copyright (c) 1997, 2000 Borland Error:
Unresolved external 'dbinit' referenced from C:\SYBASE\SAMPLE\DBLIBRARY\E
XAMPLE3.OBJ
<snip>

All of the missing symbols are defined in the sybdb library. I'm not sure
what the file is called on Windows, nor if it will work with Borland's C
compiler/linker. Still the symptom that you are seeing is indicative that
your binary is not linked with the proper Sybase library file.

Michael
--
Michael Peppler Data Migrations, Inc.
mpeppler (AT) peppler (DOT) org http://www.peppler.org/
Sybase T-SQL/OpenClient/OpenServer/C/Perl developer available for short or
long term contract positions - http://www.peppler.org/resume.html



Reply With Quote
  #3  
Old   
ScriptBoy
 
Posts: n/a

Default Re: Unresolved external function reference - 05-07-2004 , 09:00 AM



then maybe i'm giving the wrong command, which is:

bcc32 -Ic:\sybase\include -Lc:\sybase\lib example3.c

maybe you can help me with the right command


thanks for responding to my message, it was great help.

Reply With Quote
  #4  
Old   
Michael Peppler
 
Posts: n/a

Default Re: Unresolved external function reference - 05-07-2004 , 11:00 AM



On Fri, 07 May 2004 07:00:06 -0700, ScriptBoy wrote:

Quote:
then maybe i'm giving the wrong command, which is:

bcc32 -Ic:\sybase\include -Lc:\sybase\lib example3.c

maybe you can help me with the right command
YOu probably need to add
-lsybdb.lib
or something like that...

Michael
--
Michael Peppler Data Migrations, Inc.
mpeppler (AT) peppler (DOT) org http://www.peppler.org/
Sybase T-SQL/OpenClient/OpenServer/C/Perl developer available for short or
long term contract positions - http://www.peppler.org/resume.html



Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.