help... how do i use SSQLS within my own classes... 2006-12-19 - By joh3@(protected)
Back Hi, I am hoping that some of you with greater mysql++ and c++ experience can help me. What I want is to be able to use the SSQLS generated code as part of a larger object....
FYI... I can get all the example code to work fine, and i am happy using the rest of the mysql++ libs but this SSQLS area still has me stuck... anyway any help would be appreciated.
so my pseudo header code would look something like this...
<<<<file PSmh.h>>>>>
sql_create_8(Target_Region, 1, 0, mysqlpp::sql_int, Target_ID, string, Target_name, string, root_path, string, file_path, mysqlpp::sql_int, Master_id, string, Target_region_geom, string, Combined_Amplitude_image_path, mysqlpp::sql_int, resume_state)
class PSmh {/* {{{ */ // some public methods private: vector<Target_Region> My_target; }/* }}} */
however.... using this style gives me lots of compile errors.....
g++ -o psinsar logger.cxx Jerr.cxx config-handler.cxx mysql_psinsar_harmony.cxx psinsar.cxx -I. -I/usr/include/boost -I/usr/include/stlsoft -I/usr/include/mysql -g -ggdb -Wall `mysql_config --cflags` -fexceptions `gsl-config --cflags` `gsl-config --libs` `mysql_config --libs` -L/usr/lib/ -l mysqlpp -L/lib -L/usr/lib -lz -lm -lboost_program_options -L.
/tmp/ccc67q0l.o:/usr/lib/gcc/i686-pc-linux-gnu/4.1.1/include/g++-v4/exception :55: multiple definition of `Target_Region::names'
/tmp/ccsfwwq0.o:/usr/include/mysql++/lockable.h:139: first defined here
/tmp/ccc67q0l.o:/usr/lib/gcc/i686-pc-linux-gnu/4.1.1/include/g++-v4/iostream:78: multiple definition of `Target_Region::_table'
/tmp/ccsfwwq0.o:/usr/include/mysql++/noexceptions.h:60: first defined here
collect2: ld returned 1 exit status
make: *** [psinsar] Error 1
can someone give me some hints how i can get this working?
also i need to extend the mysql++ library to use the geospatial mysql extensions, i am slowly working out how mysql++ all fits together, would you like patches to make them work if i can get it working? if so how do i submit them? should they be against the svn code or the base mysql++ 2.1.1 code?
thanks in advance for all your help, and merry christmas
Cheers
Joe
-- MySQL++ Mailing List For list archives: http://lists.mysql.com/plusplus To unsubscribe: http://lists.mysql.com/plusplus?unsub=mysql@(protected)
|
|