trace file shows SQLException Unicode String cannot convert to Ebcdic on 
successful connetct with International characters
--------------------------------------------------------------------------------------------------------------------------

                 Key: DERBY-4901
                 URL: https://issues.apache.org/jira/browse/DERBY-4901
             Project: Derby
          Issue Type: Bug
          Components: Network Client
            Reporter: Kathey Marsden
            Priority: Trivial
         Attachments: NLSConnectDataSource.java, nlstrace.out

For the purposes of backward compatibility, client attempts to send the 
database converted to Ebcdic in the server attributes.  If it cannot, it will 
continue and send it in subsequent code points where it can send in UTF-8.

If a trace file is specified, e.g. with ClientDataSource.setTraceFile()   the 
trace file shows the exception and trace.  It might be confusing to have it in 
the trace file when it results in no real exception.  Maybe just a line that it 
could not be sent on EXCSAT or maybe nothing at all would be fine.


[derby] END TRACE_CONNECTS
[derby] BEGIN TRACE_DIAGNOSTICS
[derby][sqlexcept...@2c302c30] java.sql.SQLException
[derby][sqlexcept...@2c302c30] SQL state  = 22005
[derby][sqlexcept...@2c302c30] Error code = 20000
[derby][sqlexcept...@2c302c30] Message    = Unicode string cannot convert to 
Ebcdic string
[derby][sqlexcept...@2c302c30] Stack trace follows
org.apache.derby.client.am.SqlException: Unicode string cannot convert to 
Ebcdic string
        at 
org.apache.derby.client.net.EbcdicCcsidManager.convertFromJavaString(EbcdicCcsidManager.java:144)
        at 
org.apache.derby.client.net.EbcdicCcsidManager.convertFromJavaString(EbcdicCcsidManager.java:131)
        at 
org.apache.derby.client.net.NetConnectionRequest.buildRDBNAM(NetConnectionRequest.java:492)
        at 
org.apache.derby.client.net.NetConnectionRequest.buildACCSEC(NetConnectionRequest.java:299)
        at 
org.apache.derby.client.net.NetConnectionRequest.writeAccessSecurity(NetConnectionRequest.java:74)
        at 
org.apache.derby.client.net.NetConnection.writeServerAttributesAndKeyExchange(NetConnection.java:803)
        at 
org.apache.derby.client.net.NetConnection.flowServerAttributesAndKeyExchange(NetConnection.java:742)
        at 
org.apache.derby.client.net.NetConnection.flowUSRIDPWDconnect(NetConnection.java:586)
        at 
org.apache.derby.client.net.NetConnection.flowConnect(NetConnection.java:404)
        at 
org.apache.derby.client.net.NetConnection.initialize(NetConnection.java:303)
        at 
org.apache.derby.client.net.NetConnection.<init>(NetConnection.java:236)
        at 
org.apache.derby.client.net.NetConnection40.<init>(NetConnection40.java:85)
        at 
org.apache.derby.client.net.ClientJDBCObjectFactoryImpl40.newNetConnection(ClientJDBCObjectFactoryImpl40.java:282)
        at 
org.apache.derby.jdbc.ClientDataSource.getConnectionX(ClientDataSource.java:213)
        at 
org.apache.derby.jdbc.ClientDataSource.getConnection(ClientDataSource.java:167)


Also I noted the international characters print as question marks. I think this 
is normal but it might be nice if they printed as escaped unicode.

Program NLSConnectDataSource.java and nlstrace.out will be attached.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to