List:MySQL++« Previous MessageNext Message »
From:Warren Young Date:May 26 2005 3:28am
Subject:Re: Can you have more than one active mysqlpp::Connection object?
View as plain text  
Byrial Jensen wrote:
> I don't know if it is considered a bug that you cannot write
> 
>    const char *text = row[1];

The bug is in the construct, not in MySQL++.  To make that work in 
MySQL++, we'd have to return a pointer (or reference) to a static 
object, and that opens up a whole new class of risks.

MySQL++ behaves reaonably in this regard.  The question is how we make 
people understand what the reasonable behavior is.  :)

> but even if it isn't, it might be an idea to warn about the construction 
> in the manual.

The only place an outright warning about this particular error will make 
sense is in the reference manual, for Row's operator[].  But it might 
also be good to have a general discussion of concepts in the userman. 
Any ideas of where it should go, and how to approach it?
Thread
Can you have more than one active mysqlpp::Connection object?Byrial Jensen24 May
  • Re: Can you have more than one active mysqlpp::Connection object?Earl Miles24 May
  • Re: Can you have more than one active mysqlpp::Connection object?Warren Young24 May
    • Re: Can you have more than one active mysqlpp::Connection object?Byrial Jensen25 May
      • Re: Can you have more than one active mysqlpp::Connection object?Earl Miles25 May
        • Re: Can you have more than one active mysqlpp::Connection object?Chris Frey25 May
          • Re: Can you have more than one active mysqlpp::Connection object?Chris Frey25 May
            • Re: Can you have more than one active mysqlpp::Connection object?Earl Miles25 May
          • Re: Can you have more than one active mysqlpp::Connection object?Byrial Jensen25 May
            • Re: Can you have more than one active mysqlpp::Connection object?Warren Young26 May
              • Re: Can you have more than one active mysqlpp::Connection object?Byrial Jensen26 May
                • Re: Can you have more than one active mysqlpp::Connection object?Warren Young26 May