List:MySQL++« Previous MessageNext Message »
From:Nick Hastings Date:November 27 2008 2:39am
Subject:Re: Connections using MultiResultsOption
View as plain text  
Hi Warren,

* Warren Young <mysqlpp@stripped> [081127 11:30]:
> Nick Hastings wrote:
>>> I also ran the above under strace, and it seems that .my.cnf is never
>>> read when MultiResultsOption is not set.
>>
>> Anyone care to try this on their machine?
>
> Sorry for the long time in getting back to you on this.  I just tried it  
> and verified it.  You can fix it like this:
>
> con.set_option(new mysqlpp::ReadDefaultFileOption("/home/foo/.my.cnf"));
>
> Call that before you call con.connect(), and it'll work.

Cool. I'll give it a try.

> I don't think this is a MySQL++ bug.  It seems to just be a weird  
> limitation of the C API.  It's not even as simple as the C API resetting  
> the default value for the ReadDefaultFileOption, because you can set it  
> *before* you set MultiResultsOption, and this still works.  Once you've  
> set ReadDefaultFileOption explicitly instead of relying on the default  
> behavior, all is well.  If I were you, I'd file this as a bug with  
> MySQL, Inc., on libmysqlclient.

Interesting. 

I'll have a play with the C API directly then sub a bug based on what
I find.

Cheers,

Nick.

-- 
Nicholas C. Hastings, Research Staff
Aihara Group/Department of Physics, The University of Tokyo
Thread
Connections using MultiResultsOptionNick Hastings24 Jul
  • Re: Connections using MultiResultsOptionWarren Young24 Jul
    • Re: Connections using MultiResultsOptionNick Hastings24 Jul
      • Re: Connections using MultiResultsOptionNick Hastings25 Jul
        • Re: Connections using MultiResultsOptionWarren Young27 Nov
          • Re: Connections using MultiResultsOptionNick Hastings27 Nov