-
Notifications
You must be signed in to change notification settings - Fork 36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
getColumn and getExtendedSql returning blank when string is over around 120 characters #4
Comments
OK the code formating isnt very good, basically i just added this line: |
Re: [dingmaotu/mql-sqlite3] getColumn and getExtendedSql returning blank when string is over around 120 characters (#4)
Hello beerb0x,
thank you for your comment and fix. I've no problem with the string lengths earlier. Is it possible that you had some special character in the field, and not the length was the problem?
Radu
|
Im not sure what was causing it it seems to be a very strange problem to have. It was just a basic table with text & date fields populated via a Python script |
Ok I finally added my sqllite code to my system thats using the ZeroMQ library and found the actual issue. It appears the SQLITE bindings are using earlier versions of the functions from the mql4-lib library. The bug appears to have been fixed with the newer mql4-lib functions. I think the fix would be to update the sqlite bindings with the current mql4-lib project.
It appears the null terminating character is the problem and that is not included in the sqllite library |
@beerb0x |
No probs, new to github signed up to post this heh, ive fixed the others. |
I am using build 1280 of mt4 and I ran into this wierd problem, im not sure if its just me or it will effect others but i wanted to post my (dodgy) fix if anyone else runs into it. Any time i used getColumn on a table field that was larger than around 120characters or used getExtendedSql and the query was over 120 chars long i was getting a blank return value. Im no c programer but i dug around and worked out a dodgy fix just to get me out, I made a single line addition to StringFromUtf8Pointer in Common.mqh after the second call to MultiByteToWideChar.
Im no C programer and i have very little idea of what im doing so im unsure what caused this (maybe the copied string in memory doesnt quite jazz with mt4 perfectly) but my hack seems to have fixed it
The text was updated successfully, but these errors were encountered: