List:MySQL++« Previous MessageNext Message »
From:Matt Dargavel Date:October 25 2006 12:09pm
Subject:RE: Using MySQL++ in Your Own Projects
View as plain text  
My guess is that you haven't linked against the mysqlpp library.  Make sure
mysqlpp.lib is in the "Additional Dependencies" setting under
"Linker->Input", check that the path to the library is included in the
"Additional Library Directories" setting under Linker->General.


> -----Original Message-----
> From: Klemen Dovrtel [mailto:klemen_dovrtel@stripped]
> Sent: 25 October 2006 12:29
> To: plusplus@stripped
> Subject: Using MySQL++ in Your Own Projects
> 
> I compiled the library and the sample1 application and
> it works fine. The problem is, that i can't built my
> own project...
> I read in readme file that i should "Add a .cpp file
> to the solution so it _knows_ it's a C/C++
> solution."....Which .cpp file is that? I copied the
> lib directory to my project, i copied util.h and
> change the project setting similar to sample1 project
> settings...i got no errors during compiling, but i get
> a lot of linking errors. Any idea what is wrong?
> 
> I am using winxp sp2, visual studio 2005,
> mysql++-2.1.1 and mysql-essential-5.0.26-win32.
> 
> Linking...
> mysql test2.obj : error LNK2019: unresolved external
> symbol "__declspec(dllimport) public: virtual
> __thiscall mysqlpp::Connection::~Connection(void)"
> (__imp_??1Connection@mysqlpp@@UAE@XZ) referenced in
> function _wmain
> mysql test2.obj : error LNK2019: unresolved external
> symbol "__declspec(dllimport) public: class
> std::basic_string<char,struct
> std::char_traits<char>,class std::allocator<char> >
> __thiscall mysqlpp::Query::error(void)"
> (__imp_?error@Query@mysqlpp@@QAE?AV?$basic_string@DU?$char_traits@D@std
> @@V?$allocator@D@2@@std@@XZ)
> referenced in function _wmain
> mysql test2.obj : error LNK2019: unresolved external
> symbol "char * __cdecl utf8trans(char const *,char
> *,int)" (?utf8trans@@YAPADPBDPADH@Z) referenced in
> function _wmain
> mysql test2.obj : error LNK2019: unresolved external
> symbol "__declspec(dllimport) public: virtual class
> mysqlpp::ColData_Tmpl<class mysqlpp::const_string>
> const __thiscall mysqlpp::Row::at(unsigned int)const "
> (__imp_?at@Row@mysqlpp@@UBE?BV?$ColData_Tmpl@Vconst_string@mysqlpp@@@2@
> I@Z)
> referenced in function _wmain
> mysql test2.obj : error LNK2019: unresolved external
> symbol "__declspec(dllimport) public: virtual
> __thiscall mysqlpp::Row::~Row(void)"
> (__imp_??1Row@mysqlpp@@UAE@XZ) referenced in function
> _wmain
> mysql test2.obj : error LNK2019: unresolved external
> symbol "__declspec(dllimport) public: class
> mysqlpp::Query __thiscall
> mysqlpp::Connection::query(void)"
> (__imp_?query@Connection@mysqlpp@@QAE?AVQuery@2@XZ)
> referenced in function _wmain
> mysql test2.obj : error LNK2019: unresolved external
> symbol "__declspec(dllimport) public: bool __thiscall
> mysqlpp::Connection::connect(char const *,char const
> *,char const *,char const *,unsigned int,char,unsigned
> int,char const *,unsigned int)"
> (__imp_?connect@Connection@mysqlpp@@QAE_NPBD000IDI0I@Z)
> referenced in function _wmain
> mysql test2.obj : error LNK2019: unresolved external
> symbol "__declspec(dllimport) public: __thiscall
> mysqlpp::Connection::Connection(bool)"
> (__imp_??0Connection@mysqlpp@@QAE@_N@Z) referenced in
> function _wmain
> mysql test2.obj : error LNK2001: unresolved external
> symbol "public: virtual unsigned int __thiscall
> mysqlpp::Row::size(void)const "
> (?size@Row@mysqlpp@@UBEIXZ)
> mysql test2.obj : error LNK2001: unresolved external
> symbol "public: virtual class
> mysqlpp::ColData_Tmpl<class mysqlpp::const_string>
> const __thiscall mysqlpp::Row::at(unsigned int)const "
> (?at@Row@mysqlpp@@UBE?BV?$ColData_Tmpl@Vconst_string@mysqlpp@@@2@I@Z)
> mysql test2.obj : error LNK2019: unresolved external
> symbol "__declspec(dllimport) public: virtual
> __thiscall mysqlpp::ResUse::~ResUse(void)"
> (__imp_??1ResUse@mysqlpp@@UAE@XZ) referenced in
> function "public: virtual __thiscall
> mysqlpp::Result::~Result(void)"
> (??1Result@mysqlpp@@UAE@XZ)
> mysql test2.obj : error LNK2019: unresolved external
> symbol _mysql_num_rows@4 referenced in function
> "public: unsigned __int64 __thiscall
> mysqlpp::Result::num_rows(void)const "
> (?num_rows@Result@mysqlpp@@QBE_KXZ)
> mysql test2.obj : error LNK2019: unresolved external
> symbol "__declspec(dllimport) public: __thiscall
> mysqlpp::Row::Row(char * * const &,class
> mysqlpp::ResUse const *,unsigned long *,bool)"
> (__imp_??0Row@mysqlpp@@QAE@ABQAPADPBVResUse@1@PAK_N@Z)
> referenced in function "public: class mysqlpp::Row
> const __thiscall mysqlpp::Result::fetch_row(void)const
> " (?fetch_row@Result@mysqlpp@@QBE?BVRow@2@XZ)
> mysql test2.obj : error LNK2019: unresolved external
> symbol _mysql_fetch_lengths@4 referenced in function
> "public: class mysqlpp::Row const __thiscall
> mysqlpp::Result::fetch_row(void)const "
> (?fetch_row@Result@mysqlpp@@QBE?BVRow@2@XZ)
> mysql test2.obj : error LNK2019: unresolved external
> symbol _mysql_fetch_row@4 referenced in function
> "public: class mysqlpp::Row const __thiscall
> mysqlpp::Result::fetch_row(void)const "
> (?fetch_row@Result@mysqlpp@@QBE?BVRow@2@XZ)
> mysql test2.obj : error LNK2019: unresolved external
> symbol _mysql_data_seek@12 referenced in function
> "public: void __thiscall
> mysqlpp::Result::data_seek(unsigned int)const "
> (?data_seek@Result@mysqlpp@@QBEXI@Z)
> mysql test2.obj : error LNK2019: unresolved external
> symbol "__declspec(dllimport) public: class
> mysqlpp::Result __thiscall mysqlpp::Query::store(class
> mysqlpp::SQLQueryParms &)"
> (__imp_?store@Query@mysqlpp@@QAE?AVResult@2@AAVSQLQueryParms@2@@Z)
> referenced in function "public: class mysqlpp::Result
> __thiscall mysqlpp::Query::store(void)"
> (?store@Query@mysqlpp@@QAE?AVResult@2@XZ)
> 
> 
> __________________________________________________
> Do You Yahoo!?
> Tired of spam?  Yahoo! Mail has the best spam protection around
> http://mail.yahoo.com
> 
> --
> MySQL++ Mailing List
> For list archives: http://lists.mysql.com/plusplus
> To unsubscribe:    http://lists.mysql.com/plusplus?unsub=1
> telecoms.com

Thread
Using MySQL++ in Your Own ProjectsKlemen Dovrtel25 Oct
  • Re: Using MySQL++ in Your Own ProjectsWarren Young25 Oct
  • RE: Using MySQL++ in Your Own ProjectsMatt Dargavel25 Oct