List:MySQL++« Previous MessageNext Message »
From:Don Thompson Date:October 8 2004 6:40pm
Subject:Re: compiling mysql++ examples (fwd)
View as plain text  
Hi,
You're right,  the junk was test code with const qualifier, but it 
should be removed for my example,
ie query.insert(*this).  Using this change, I get the complaint about 
const:  I know we're getting
into c++ issues here.

thanks

------------------------------------------------------------------------

/usr/local/mysql++-1.7.15/sqlplusint/sql_query1.hh: In member function `
   SQLQuery& SQLQuery::insert(const T&) [with T = CLdata]':
/usr/local/mysql++-1.7.15/sqlplusint/query1.hh:83:   instantiated from `MysqlQuery&
MysqlQuery::insert(const CLdata&) [with T = CLdata]'
cudb.cc:21:   instantiated from here
/usr/local/mysql++-1.7.15/sqlplusint/sql_query1.hh:178: error: passing `const 
   CLdata' as `this' argument of `std::string& CLdata::value_list()' discards 
   qualifiers
/usr/local/mysql++-1.7.15/sqlplusint/sql_query1.hh:178: error: passing `const 
   CLdata' as `this' argument of `std::string& CLdata::field_list()' discards 
   qualifiers
/usr/local/mysql++-1.7.15/sqlplusint/sql_query1.hh:178: error: passing `const 
   CLdata' as `this' argument of `SQLString& CLdata::table()' discards 
   qualifiers
make[3]: *** [cudb.o] Error 1



Warren Young wrote:

> Don Thompson wrote:
>
>>   const CLdata junk(*this);
>
>
> I don't see why that is necessary...
>
>>   query.insert(&junk);
>
>
> Try query.insert(junk).  Or, with my first comment in mind, 
> query.insert(*this).
>



Thread
compiling mysql++ examples (fwd)Enrique Farfan5 Oct
  • Re: compiling mysql++ examples (fwd)Warren Young5 Oct
  • Re: compiling mysql++ examples (fwd)Don Thompson8 Oct
    • Re: compiling mysql++ examples (fwd)Warren Young8 Oct
  • Re: compiling mysql++ examples (fwd)Don Thompson8 Oct
    • Re: compiling mysql++ examples (fwd)Warren Young8 Oct
      • Re: compiling mysql++ examples (fwd)Don Thompson9 Oct
        • Re: compiling mysql++ examples (fwd)Chris Frey9 Oct