Feedback
Did this article resolve your question/issue?

   

Article

COPY-LOB that works when running with shared memory or single user connection fails with Client/Server connection

Information

 
TitleCOPY-LOB that works when running with shared memory or single user connection fails with Client/Server connection
URL Name000052639
Article Number000170886
EnvironmentProduct: OpenEdge
Version: OpenEdge 10.2B07, 11.3.2.0
OS: All supported platforms
Other: COPY-LOB, Shared Memory Connection, Client Server Connection
Question/Problem Description
COPY-LOB that works when running with shared memory connection fails with Client/Server connection.

COPY-LOB used to populate a UTF-8 database table field fails if the database connection is client/server (-H -S).

Same COPY-LOB code succeeds if the database connection is a shared memory connection or a single user connection.
Steps to Reproduce
Clarifying Information
Steps to reproduce:

1.  Login onto a Windows machine with OpenEdge 11.3.2.
 
2.  Copy the files in the attached 000052639.zip to the OpenEdge Working Directory.
 
3.  Create an empty UTF-8 database:
prodb Bug %DLC%\prolang\utf\empty.db
 
4.  Use the Database Administration tool to load the attached bug.df:
prowin32 Bug -1 -cpinternal utf-8 -cpstream utf-8 -cpterm utf-8 -cpcoll basic -cpcase basic -p _admin
 
5.  Run the attached test.p which uses COPY-LOB from LONGCHAR to FIELD:
prowin32 Bug -1 -cpinternal utf-8 -cpstream utf-8 -cpterm utf-8 -cpcoll basic -cpcase basic -p test.p
 
6.  Observe no errors are generated.
 
7.  Run the attached EmptyTable.p to delete the record created in the above step.
prowin32 Bug -1 -cpinternal utf-8 -cpstream utf-8 -cpterm utf-8 -cpcoll basic -cpcase basic -p EmptyTable.p
 
 
8.  Run the attached test2.p which uses COPY-LOB from FILE to FIELD:
prowin32 Bug -1 -cpinternal utf-8 -cpstream utf-8 -cpterm utf-8 -cpcoll basic -cpcase basic -p test2.p
 
9.  Observe no errors are generated.
 
 
10.  Run the attached EmptyTable.p to delete the record created in the above step.
prowin32 Bug -1 -cpinternal utf-8 -cpstream utf-8 -cpterm utf-8 -cpcoll basic -cpcase basic -p EmptyTable.p
 
11. Start the database using using the -H and the -S startup parameters (Change -H and -S values to reflect your environment):
proserve Bug -H HostName -S PortNumber
 
12.  Run the attached test.p which uses COPY-LOB from LONGCHAR to FIELD (Change -H and -S values to reflect your environment):
prowin32 -db Bug -H HostName -N TCP -S PortNumber -cpinternal utf-8 -cpstream utf-8 -cpterm utf-8 -cpcoll basic -cpcase basic -p test.p
 
13.  Observe the following two errors are generated:
Failure in large object operation, error = -9 (16683)
Could not update large object segment during copy. (11322)
 
14.  Run the attached EmptyTable.p to delete the record created in the above step.
prowin32 -db Bug -H HostNmae -N TCP -S PortNumber -cpinternal utf-8 -cpstream utf-8 -cpterm utf-8 -cpcoll basic -cpcase basic -p EmptyTable.p
 
 
15.  Run the attached test2.p which uses COPY-LOB from FILE to FIELD (Change -H and -S values to reflect your environment):
prowin32 -db Bug -H HostName -N TCP -S PortNumber -cpinternal utf-8 -cpstream utf-8 -cpterm utf-8 -cpcoll basic -cpcase basic -p test2.p
 
16.  Observe the following three errors are generated:
Invalid character code found in data for codepage UTF-8 (12008)
Failed to create/update blob from file 'myutf8file.txt'. (11275)
COPY-LOB failed to copy file 'myutf8file.txt' to large object. (11300)
 
17.  Run the attached EmptyTable.p to delete the record created in the above step.
prowin32 -db Bug -H HostName -N TCP -S PortNumber-cpinternal utf-8 -cpstream utf-8 -cpterm utf-8 -cpcoll basic -cpcase basic -p EmptyTable.p
 
 
18.  Run the attached test.p with shared memory connection:
prowin32 Bug -cpinternal utf-8 -cpstream utf-8 -cpterm utf-8 -cpcoll basic -cpcase basic -p test.p
 
19.  Observe no errors are generated.
 
20.  Run the attached EmptyTable.p to delete the record created in the above step.
prowin32 Bug -cpinternal utf-8 -cpstream utf-8 -cpterm utf-8 -cpcoll basic -cpcase basic -p EmptyTable.p
 
21.  Run the attached test2.p with shared memory connection:
prowin32 Bug -cpinternal utf-8 -cpstream utf-8 -cpterm utf-8 -cpcoll basic -cpcase basic -p test2.p
 
22.  Observe no errors are generated.
Error Message
Defect/Enhancement NumberDefect PSC00311529
Cause
The server is returning an error because when it got the data to be written into the CLOB, it noticed it had a split character.
The client sends the data in chunks using code to make sure no split characters are sent.
Resolution
Upgrade to OpenEdge 11.3.3.0
Upgrade to OpenEdge 11.5.0.0 or later
Workaround
Notes
Last Modified Date12/14/2018 12:45 PM
Attachment 
Files 1. 000052639.zip
Disclaimer The origins of the information on this site may be internal or external to Progress Software Corporation (“Progress”). Progress Software Corporation makes all reasonable efforts to verify this information. However, the information provided is for your information only. Progress Software Corporation makes no explicit or implied claims to the validity of this information.

Any sample code provided on this site is not supported under any Progress support program or service. The sample code is provided on an "AS IS" basis. Progress makes no warranties, express or implied, and disclaims all implied warranties including, without limitation, the implied warranties of merchantability or of fitness for a particular purpose. The entire risk arising out of the use or performance of the sample code is borne by the user. In no event shall Progress, its employees, or anyone else involved in the creation, production, or delivery of the code be liable for any damages whatsoever (including, without limitation, damages for loss of business profits, business interruption, loss of business information, or other pecuniary loss) arising out of the use of or inability to use the sample code, even if Progress has been advised of the possibility of such damages.