Comments (8)
Hi,
You could just use mariadb. On the systems that I know that use mariadb, there are libmysql* symbolic links. If those are not present on your system, maybe you could extend the FindMySql.cmake
file and create a pull request? That would be great!
As for the Windows part: For quite some time I could not get libmysql to link with anything I built on appveyor. I was experimenting with mariadb and had compilation problems. I reported a few bugs and gave up. Some of this seems to be fixed now as the appveyor builds complete successfully but it is certainly not in a very good state.
from sqlpp11-connector-mysql.
I have tried, everything went well except for the second test, i.e., SampleTest. The
second test failed while reallocating buffer, the following gives the detail:
2: MySQL debug: Preparing: 'SELECT tab_sample.alpha,tab_sample.beta,tab_sample.gamma FROM tab_sample WHERE (((tab_sample.alpha<>?) AND (tab_sample.beta<>?)) AND (tab_sample.gamma<>?))'
2: MySQL debug: Constructing prepared_statement, using handle at 0x20628d0
2: MySQL debug: binding integral parameter 7 at index: 0, being not null
2: MySQL debug: binding text parameter wurzelbrunft at index: 1, being not null
2: MySQL debug: binding boolean parameter true at index: 2, being not null
2: MySQL debug: Executing prepared_statement
2: MySQL debug: Constructing bind result, using handle at 0x20628d0
2: MySQL debug: binding integral result 0 at index: 0
2: MySQL debug: binding text result at index: 1
2: MySQL debug: binding boolean result
2: at index: 2
2: MySQL debug: Binding results for handle at 0x20628d0
2: MySQL debug: Accessing next row of handle at 0x20628d0
2: MySQL debug: Need to reallocate buffer at index 1 for handle at 0x20628d0
2: Exception: MySQL: Fetch column after reallocate failed:
2/6 Test #2: SampleTest .......................***Failed 0.23 sec
It seems that this exception is thrown by bool bind_result_t::next_impl()
in bind_result.cpp.
Do you have any hint for me to solve it?
Thanks!
-- Long
from sqlpp11-connector-mysql.
Hmm, that looks strange.
Can you try to dig deeper into the problem by printing r.bound_len
, param.buffer_length
and the actual return value of mysql_stmt_fetch_column
?
Thanks,
Roland
from sqlpp11-connector-mysql.
After a deeper dig, I got the following mysql error code:
Error: 2051 (CR_NO_DATA)
Message: Attempt to read column without prior row fetch
Original exception output is:
Exception: MySQL: Fetch column after reallocate failed: 2051
To get the above output, I changed mysql_stmt_error
to mysql_stmt_errno
in bind_result.cpp, since
I got nothing (empty string) from mysql_stmt_error
.
Thanks!
- Long
from sqlpp11-connector-mysql.
Please try again with the new version on develop. It does not change anything functionally but prints a few more messages.
Which library are you using? mysql or mariadb, which version?
from sqlpp11-connector-mysql.
My mysql server version is: mysql Ver 14.14 Distrib 5.7.17, for Linux (x86_64) using EditLine wrapper
For the connector, I used mariadb client (3.0.2) instead of mysqlclient.
The following is exception thrown when running ctest
on the new version on develop.
2: Exception: MySQL: Fetch column after reallocate failed: error-code: 1, stmt-error: , stmt-errno: 2051
from sqlpp11-connector-mysql.
Thanks. I'll need some time to setup mariadb.
from sqlpp11-connector-mysql.
See #39 (it is a maria db client bug it seems).
Closing this one.
from sqlpp11-connector-mysql.
Related Issues (20)
- Data is truncated with MariaDB Connector/C 3.0.1+ HOT 11
- Selecting a datetime field always returns epoch HOT 2
- Microseconds ignored when selecting datetime column HOT 1
- Mac osX build HOT 8
- Crash of queries due to MYSQL_RES that is NULL HOT 7
- mysql replace into command HOT 5
- how to use unhex function ,could you give some info? HOT 1
- database name not used HOT 2
- sample code does not work on windows HOT 1
- Can't build DLL on windows HOT 2
- {char,bind}_result_t.size() is unimplemented HOT 5
- How to create mysql::connection without config HOT 2
- TLS/SSL connection is unsupported HOT 1
- Does sqlpp11 support a connection pool? What do I need to do? HOT 2
- How to return mysql auto incorrect when inserting a record in the table? HOT 2
- how can I set mysql options HOT 1
- Error reported while installing sqlpp11-mysql HOT 4
- Why is it necessary to pass database parameter when creating a connection? HOT 3
- Error when compiling HOT 5
- build failed on linux HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sqlpp11-connector-mysql.