On 11-2-2012 15:54, Mark Rotteveel wrote: > I am looking for the cause of CORE-3701 / JDBC-233, but I can't identify > the problem. > > The problem is this: When using Jaybird native (using fbclient 2.5.1) > the parametrized insert of a single character into a CHAR(1) column > fails with error: > 335544569. Dynamic SQL Error > SQL error code = -303 > arithmetic exception, numeric overflow, or string truncation > string right truncation
[...snip...] > I can't seem to find the problem in the Java code nor in the native code > of Jaybird. Could someone with more familiarity with the Firebird server > or fbclient side look at it. > > JDBC-233 contains a reduced example (for Windows with a 32 bit JVM) with > a readme.txt with instructions to execute it. > > This example contains the current Jaybird 2.2 jar and dll, but this > could easily be replaced with the Jaybird 2.1.6 jar and dll (or .so). And just after I sent my mail I thought of a potential cause which I am now investigating. It looks like the XSQLVAR sqllen field 4, while the data array was only 1 entry long. Reducing the sqllen to the actual length of the array *or* padding the array seems to fix it. Which course of action would be better? Padding the data array or reducing the sqllen to the actual length? Mark -- Mark Rotteveel ------------------------------------------------------------------------------ Virtualization & Cloud Management Using Capacity Planning Cloud computing makes use of virtualization - but cloud computing also focuses on allowing computing to be delivered as a service. http://www.accelacomm.com/jaw/sfnl/114/51521223/ Firebird-Devel mailing list, web interface at https://lists.sourceforge.net/lists/listinfo/firebird-devel