Hello!
We are using sqlrelay 0.39.4 with Oracle. There are 2 problems with
output string bind variables:
1) When you prepare cursor, bind output variable and then execute it in
a loop, size of bind variable changes from one iteration to another - it
becomes the size of return value from previous iteration. For example,
if result in first iteration was 'abc', then size of output bind in next
iteration will be 3, no matter what value you put in
sqlrcur_defineOutputBindString.
2) For Unicode strings, when one character fits one or more bytes, max
output buffer for string variables is 32464 bytes, not characters, so
russian strings (1 char = 2 bytes) are cut to 17232 characters
Test script can be found here:
http://www.srr.pp.ru/www/sqlr/test_sqlr.htms
It prints page like this:
Example 1:
1 ok: strlen_ora=7 != strlen=7|БЭгЮхВП|
2 error: strlen_ora=10 != strlen=7|ЛлаЕМШВ|
3 error: strlen_ora=8 != strlen=7|рДРуУлЗ|
Example 2:
1 error: strlen_ora=25268 != strlen=17232
2 error: strlen_ora=23904 != strlen=17232
3 error: strlen_ora=23095 != strlen=17232
Debug output can be found here:
http://www.srr.pp.ru/www/sqlr/debug_utf8.txt
--
Renat Sabitov e-mail: sr...@st...
Stack Soft jid: sr...@ja...
|