<html>
<head>
<base href="https://bugs.documentfoundation.org/">
</head>
<body>
<p>
<div>
<b><a class="bz_bug_link
bz_status_NEW "
title="NEW - SQL... dialog Status: "Commands out of sync" when connecting to MySQL using direct (native) connector"
href="https://bugs.documentfoundation.org/show_bug.cgi?id=103685#c15">Comment # 15</a>
on <a class="bz_bug_link
bz_status_NEW "
title="NEW - SQL... dialog Status: "Commands out of sync" when connecting to MySQL using direct (native) connector"
href="https://bugs.documentfoundation.org/show_bug.cgi?id=103685">bug 103685</a>
from <span class="vcard"><a class="email" href="mailto:lionel@mamane.lu" title="Lionel Elie Mamane <lionel@mamane.lu>"> <span class="fn">Lionel Elie Mamane</span></a>
</span></b>
<pre>(In reply to Julien Nabet from <a href="show_bug.cgi?id=103685#c12">comment #12</a>)
<span class="quote">> Indeed, I began with:
> diff --git a/mysqlc/source/mysqlc_statement.cxx
> b/mysqlc/source/mysqlc_statement.cxx
> index 3a082004831a..9ff3ce163fb6 100644
> --- a/mysqlc/source/mysqlc_statement.cxx
> +++ b/mysqlc/source/mysqlc_statement.cxx
> @@ -240,7 +240,7 @@ sal_Bool SAL_CALL OCommonStatement::getMoreResults()
>
> // if your driver supports more than only one resultset
> // and has one more at this moment return true
> - return false;
> + return cppStatement->getMoreResults();
> }</span >
This looks good.
<span class="quote">> but then, I don't know how to call getMoreResults() from directsql.cxx.</span >
See the algorithm linked to in <a href="show_bug.cgi?id=103685#c13">comment 13</a>.
<span class="quote">> I tried to declare OStatement::getMoreResults</span >
No need, it inherits it from OCommonStatement.
<span class="quote">> (because OStatementBase::getMoreResults already exists) in statement.hxx +
> statement.cxx but I've got an error when building.</span >
While it is not necessary, it is definitely allowed. What error did you get?
<span class="quote">> I think it's perhaps linked to XStatement.idl but don't want to touch this
> since it's a public interface and I don't know the consequences.</span >
Yes, don't change that.
<span class="quote">> I also tried to use XMultipleResults but since execute method doesn't return
> anything, I can't use XMultipleResults</span >
The XMultipleResults interface is exactly what you have to use. But I see that
mysqlc doesn't implement it, which is... "dommage" because it is pretty easy
since MySQL Connector C++ implements it!
Something like:
sal_Int32 SAL_CALL OCommonStatement::getUpdateCount()
{
- return 0;
+ return cppStatement->getUpdateCount();
}
in addition to your above patch should be all that is needed.</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>