Since I upgraded to LEAP 15.1 I can not run "old" C applications executing mysql_query() function.
I got:
MySQL client version: 10.4.3
Tentative de connexion... [ok]
(01064)Erreur lors de l'exécution d'une requête SQL:
With no message concerning the mysql_error() function.
None of the applications done previously are still working :{
I use libmariadb-devel 3.1.2-lp151.3.3.1 (it worked with 3.0.3) it started to stop working with 3.0.7.
Try to downgrade to 3.0.3 but this version in no longer "reachable" from the repository of LEAP 15.1.
if ( mysql_query(
connexion,
"SELECT Nom,CodePostal
FROM CodesPostaux,Localités
WHERE idCodePostal=Ref_CodesPostaux ORDER BY CodePostal"))
{
wprintf(L"(%05d) ...: %s !!\n",
mysql_errno(connexion),
mysql_error(connexion));
exit(1);
}
I may have the result set displayed as usual before upgrading to 15.1 (to libmariadb-3.3.1).
This is the default charset for the server:
default-character-set = utf8
This statement (code) worked perfectly BEFORE the update. I tried to have more details concerning the 01064 error with mysql_sqlstate() function... it gives 42000...
MariaDB [CSSMPoste]> select Nom, CodePostal FROM CodesPostaux, Localités WHERE idCodePostal = Ref_CodesPostaux ORDER BY CodePostal ;
+-------------------+------------+
| Nom | CodePostal |
+-------------------+------------+
| Liège | 4000 |
| Rocourt | 4000 |
| Cointe | 4000 |
| Wandre | 4020 |
| Vottem | 4041 |
| Milmort | 4041 |
| Boncelles | 4100 |
| Seraing | 4100 |
| Jemeppe-sur-Meuse | 4101 |
| Flémalle | 4400 |
| Ans | 4430 |
| Alleur | 4432 |
| Grâce-Hollogne | 4460 |
| Amel | 4770 |
+-------------------+------------+
14 rows in set (0.01 sec)