Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 11.0.1 (Français) » QAnywhere » Writing QAnywhere client applications


Reading very large messages

Sometimes messages are so large that they exceed the limit set with the QAManager property MAX_IN_MEMORY_MESSAGE_SIZE or its defaults of 1MB on Windows and 64KB on Windows Mobile. In this case, the message object cannot contain the full content of the message in memory, so methods that rely on the full content of the message being loaded into memory, such as readInt() and readString(), cannot be used. However, you can read very large messages directly from the message store in pieces. To do this, use QATextMessage.readText() or QABinaryMessage.readBinary() in a loop.

For more information, see:

When you do this, you cannot use a QAManager that was opened with IMPLICIT_ACKNOWLEDGEMENT. You must use a QAManager that was opened with EXPLICIT_ACKNOWLEDGEMENT and you must complete all calls to readText() or readBinary() before acknowledging the message.

See Acknowledgement modes.