Page 1 of 1
GetDatabaseString text over 255 chars
Posted: Thu Sep 28, 2006 1:52 pm
by mcsalsa
I have develop a small program that access an Access Database, in the table there are fields which are Memo Fields.
I store the field in a String variable, when retrieving the data out of the memo fields with texts of more than 255 chars the result that I'm having is that the variable contains only 255 chars the rest are truncated.
Do you have experienced this problem? If so what I'm doing wrong.
Thanks in advance.
Posted: Thu Sep 28, 2006 7:42 pm
by Trond
Are you sure the string is not stored as truncated in the database?
Posted: Thu Sep 28, 2006 8:04 pm
by Fred
There is no hardcoded limit in GetDatabaseString() with v4, so it should handle any size.
Posted: Thu Sep 28, 2006 10:36 pm
by Dare
Access limits strings (text) to 255. Memo type fields allow longer strings.
Posted: Fri Sep 29, 2006 10:20 am
by CSAUER
That's right. Memo can have longer values, but they are not working correctly with GetDatabaseString(). I had some problems in the past (I used PB 3.94) and I solved the problem, by splitting the strings into a few 255 char fields and put them together into one string, after receiving data from database.
If you use MySQL, you would not have this problems, I think. So it sounds to me, that it has something to do with Access.
Posted: Fri Sep 29, 2006 12:38 pm
by Tranquil
I dont have any problems with MEMO type and long strings. could you please give an example of your problem? It is maybe intressting for other DB app coders.
Posted: Fri Sep 29, 2006 10:23 pm
by mcsalsa
Hello Tranquil,
Here you have an example:
2303,„ƒ„ƒ‚„ƒ„„‚„„„„ƒ„…„ƒ„…ƒƒ‚‡„‚ƒ……ƒƒƒ‚‚„ƒ‚‚‚ƒ
Posted: Fri Sep 29, 2006 11:59 pm
by Xombie
You're not dealing with any null characters in there, are you?
Posted: Sat Sep 30, 2006 11:10 am
by mcsalsa
Hello Xombie,
No, I'm not dealing with NULL chars. If is there any ascii 0, I escape to ascii 255
Posted: Sat Sep 30, 2006 5:50 pm
by Tranquil
I will try this @work monday. thanks for fast answer.