Questions tagged [mysql-connector-c]
31 questions
3
votes
0 answers
MySQL Connector/C++ in Xcode 9.2 via Homebrew usage problems
I've successfully installed MySQL, Boost and mysql-connector-c++ on my macOS High Sierra 10.13.3 via Homebrew, but i've ran into problems with using those libs in Xcode.
So, my boost and connector libs are located at /usr/local/Cellar/. So i just…

endlessborland
- 59
- 6
3
votes
1 answer
`brew link mysql` gives "Error: Could not symlink bin/my_print_defaults"
brew install mysql-connector-c
gave:
Error: Cannot install mysql-connector-c because conflicting formulae are installed.
mysql: because both install MySQL client libraries
Please `brew unlink mysql` before continuing.
So:
brew unlink…

Snowcrash
- 80,579
- 89
- 266
- 376
2
votes
1 answer
C program cannot get result value from MySQL procedure
I am practicing with getting a value back from a MySQL stored procedure
So I first created the following procedure
USE testdb;
DROP PROCEDURE IF EXISTS `testdb`.`get_return_value_test`;
DELIMITER $$
CREATE PROCEDURE IF NOT EXISTS…

Ctrl_halt
- 43
- 4
2
votes
1 answer
Static library (/MT) linking conflicts with project /MTd option
My project links a lot of static libraries. All of them previously links well, but now I added mysql c api library and now I gets errors like that:
mysqlclient.lib(client_authentication.obj) : error LNK2038: mismatch detected for…

urbanzz
- 127
- 8
1
vote
1 answer
How do I use 2 libraries with same external symbols?
I have 2 libraries in my project - MySQL C++ Connector and OpenSSL library for sockets, and as I think MySQL library already has OpenSSL functions inside.
Errors I get
Errors I get (in text format):
1>libcrypto.lib(libcrypto-lib-x509_d2.obj) : error…

abdul
- 13
- 3
1
vote
1 answer
C++ with sql connector getting metadata without asking for to much data
I just started working with the sql conenctor in C++ (and sql).
I need to write a bunch of header files from objects out of a database. (MariaDB but would be great if it works on all sql dbs)
My Solution so far is getting the tablenames with
res =…

Brueni
- 53
- 7
1
vote
1 answer
mysql-connector-c++ 8.0 connection refused
I'm using the mysql-connector-c++ 8.0 after getting it working with great difficulty and now the uri I've entered is as their mentioning in the docs but the connection is refused.
What the doc says:
Client cli("user:password@host_name/db_name",…

SagunKho
- 985
- 10
- 26
1
vote
1 answer
In C, why do preferred RDBMS' drivers implement different API, instead of a uniform API?
In Java, mostly different RDBMS' drivers implement JDBC API.
In Python, mostly different RDBMS' drivers implement DB-API2.
In C, although we have ODBC as uniform API for different RDBMS', people in general prefer RDBMS-specific API, such as those…

Tim
- 1
- 141
- 372
- 590
1
vote
2 answers
How can I compile mysql-connector-c for macOS 10.13.x using C?
Synopsis
I have a small c program, it's a standard "hello world" application to test I can access the mysql connection driver accordingly:
#include
#include "mysql.h"
int main(int argc, const char **argv)
{
printf("MySQL client…

Ash
- 3,242
- 2
- 23
- 35
1
vote
2 answers
mySQL Connector/C issue
ALL,
std::wstring query2 = L"SELECT cols.column_name, cols.data_type, cols.character_maximum_length, cols.character_octet_length, cols.numeric_precision, cols.numeric_scale, cols.column_default, cols.is_nullable, cols.ordinal_position, (CASE…

Igor
- 5,620
- 11
- 51
- 103
0
votes
0 answers
Mysql error - undefined reference to `mysql_real_connect' and others
I am trying to move a client app from an old box running openSUSE 13.2 (Harlequin) (i586) to a Raspberry pi running Raspbian GNU/Linux 11 (bullseye) (32-bit OS).
The old box is running Ver 15.1 Distrib 10.0.27-MariaDB, for Linux (i686) using…

Nigel W Johnson
- 1
- 1
0
votes
1 answer
pass MySQL connection to c function or use it globally
I want to create MySQL connection in one function (file) in a C project and then use that connection globally (access it in every function or file in the project). Is that possible and what is the logic (pattern) I should follow?
Thanks!

Ivo
- 1
- 2
0
votes
1 answer
MYSQLConnection call to @database.setter incorrectly routes to the _mysql_connector c-extenstion
Running on Mac Big Sur 11.6.2
Using Python 3.8
Mysql 8.0.29 Homebrew
MYSQLConnection call to @database.setter, i.e. db_conn.database = my_db_name, incorrectly routes to the _mysql_connector c-extenstion, but I don not have the c extension installed,…
0
votes
0 answers
mariadb c-connector bind / execute mess up memory allocation
i'm using mariadb c-connector with prepare, bind and execute. it works usualy. but one case end up in "corrupted unsorted chunks" and core dumping when freeing bind buffer. i suggest the whole malloc organisation is messed up after calling…

SwissGeorge
- 49
- 4
0
votes
1 answer
mysql c api interface: how to make bulk fetch : array of structures
In ProC oracle, to get "bulk rows from a table(s) in one shot" ( without any for loop iteration in code) : we use Embedded sql calls to declare cursor to define a sql select statement . Then we used to make cursor open call and then finally we make…

shibendra chakraborty
- 91
- 1
- 1
- 5