Libmysql 1264 error


I'm using libmysql.dll library to connect to my database from metatrader4. I managed to connect and things are going almost fine. I use mysql_real_connect and mysql_errno for connecting and capturing possible errors. Im using Innodb and STRICT_TRANS_TABLES in sql mode. It updates fine the ticks. The problem comes when certain conditions are met (dont know which...yet) the experts return a mysql 1264 warning. It is a data out of range warning. Although I can output the number error I would like to know exactly where it happens since if I try to manually update/insert, etc my database I get no warnings and/or errors. Is there a way to issue a "show warnings" and get the full warnings message (I've tried issuing a "show warning" query but I cant manage to retrieve a full message, only some garbled caracters....) ?

Basically, I would like to know if this is a libmysql bug or find out what's going on where (table/field responsible...)

Could someone give me some pointers?

Thank you