Hi Nico
The length of a string variable is determined by the underlying data type that is used to store strings in the database. The limits will depend on the particular database type you're using. For example, I believe the standard Oracle varchar2 is limited to just 2K.
I have two suggestions for you:
1. Use a binary varible. This is generally implemented in that database as a Long Raw value, and should be effectively unlimited in size. The downside is that many of the existing QPACs may not be able to deal very well with binary variables.
2. Use a Document variable. An Adobe document variable is a little like a String (or really a binary) on steroids. It basically works like a binary, but has a threshold value (default of 64K), over which it will store the file in the file system rather than in the database. This has some significant advantages, including limiting the growth of your database. It also has some clever caching mechanisms, support for clustering, etc. A document variable is a little more difficult to deal with in your custom QPAC, but not much -the com.adobe.idp.Document type should be fairly self-explanatory. Documents are good, because they tend to be the default type that most of the Adobe QPACs use when dealing with large amounts of data.
Please also be aware that some databases (eg MySQL) have other limitations, such as the total number of binary/longvarchar columns that you can define in any one table. So you need to do some experimentation in that area as well.
I hope this helps.
Let us know you you get on.
Howard
http://www.avoka.com