Issue while deploying application in WAS 6.1
@ankur8819-Y8pKwX
•
Oct 21, 2024
Oct 21, 2024
884
Hi guys,
I was trying to learn Hibernate and I am stuck at a issue.If anyone knows how to fix it do let me know.
I have a Web Application deployed on WAS 6.1.it uses Hibernate for Persistence.
When I am using Struct Descriptor and creating objects in Java they are being shown as ???.
I was able to fix this issue by adding orai18.jar in TomCat but in WAS I am not able to fix it.
Below is my code.
Can you please provide any pointers for the same.orai18 jar is not working..
WAS6.1 and Jdk 1.5 is the runtime environment
I am attaching the snapshot of the same.
Regards,
Ankur
I was trying to learn Hibernate and I am stuck at a issue.If anyone knows how to fix it do let me know.
I have a Web Application deployed on WAS 6.1.it uses Hibernate for Persistence.
When I am using Struct Descriptor and creating objects in Java they are being shown as ???.
I was able to fix this issue by adding orai18.jar in TomCat but in WAS I am not able to fix it.
Below is my code.
Connection conn1= session.connection(); //This is the Proxy Connection from Hibernate
Connection conn = BorrowedConnectionProxy.getWrappedConnection(conn1); Extracting from the Proxy connection
Connection nativeConnection = (Connection)WSJdbcUtil.getNativeConnection((WSJdbcConnection)conn);//getting the Native connection.In this case it comes as LogicalConnection
structDesc = StructDescriptor.createDescriptor("XXX.ESN_DATA_TYPE", nativeConnection);
arrayDesc = ArrayDescriptor.createDescriptor("XXX.ESN_DATA_TABLE", nativeConnection);
row=new Objectcount[5];
STRUCT rowStruct = new STRUCTcount;
List<STRUCT> allRows= new ArrayList<STRUCT>();
for(int i=0;i<count;i++)
{
dataDTO = (EsnDataDTO)datalist.get(i);
row[0]=dataDTO.getEngineSerialNumber();
//I even tried this row[0]=new CHAR(dataDTO.getEngineSerialNumber(), CharacterSet.make(CharacterSet.WE8ISO8859P9_CHARSET));
row[1]=dataDTO.getDescription();
row[2]=dataDTO.getTransactionDate();
row[3]=null;
row[4]=dataDTO.getUploadedBy();
rowStruct = new STRUCT(structDesc,nativeConnection,row);
/* Step 6 */
allRows.add(rowStruct); //At this point when I inspect rowStruct variable I can see data as ??? instead of values.
}Can you please provide any pointers for the same.orai18 jar is not working..
WAS6.1 and Jdk 1.5 is the runtime environment
I am attaching the snapshot of the same.
Regards,
Ankur