Handling of BLOB in OSB 11
Hi,
We have a requirement to handle a BLOB in webservice. The data will passed to this web service from another web service and it needs to be stored to a topic.
One web service will pick this data up, do some transformations and publish it to MQ topic.
The data picked from the topic before transformation has to be conforming to a schema definition.
Can you please point me to source where can i find more information about handling BLOB, or any use cases and problems faced?
Thanks
I think the requirement here is for your osb service to handle binary data, which you call BLOB here. To transport binary data in xml you need to use base 64 encoding. The source webservice should package the blob content as base64 encoded on on base64 type field in a schema and then your web service can process on that field by doing bae 64 decoding.
Search the forum, there are many threads discussing on base64 encoding/decoding.
Similar Messages
-
How to handle Asynchronous calls using OSB?
Hi There,
How to handle Asynchronous calls using OSB?
Please help me out??
-VenkatHello friend, here is what you need.
Oracle Service Bus, invoke asynchronous webservices | Oracle .. Java .. OpenSource .. SOA -
Query regarding handling and monitoring of OSB Errors in a specific manner
Hi,
I'm using
- OSB 10gR3 (10.3.1)
Context
To give some context, the setup I currently have a proprietory frontend client that is making XML/HTTP requests to OSB
which in turn is getting info from downstream systems.
I have no control over the behaviour/logic of the frontend client .. apart from knowing that it has a specific
request/response format.
So now to the issue..
The issue I'm facing is regarding handling of errors. Based on my knowledge of OSB, the error handling of the transaction has been
built along these lines
(Within the stage) If an error scenario's occurred, error is being thrown
(Within the error handler stage) Logging the error (using the 'Log' function .. with severity 'Error')
(Within the error handler stage) The response payload is being built .. so that the error can be reported to the frontend client
(Within the error handler stage) I'm doing a 'Reply with Success'
Now this does give me the expected behavior from the frontend client's perspective (... i.e. it receives the payload and displays whatever error that's occurred)
However from OSB's perspective, because I have done a 'Reply with success', the OSB Service Health Page ... (screenshot below) does not
increment the 'Errors' count for the respective proxy service ....
[OSB Service Health Page|http://download.oracle.com/docs/cd/E13159_01/osb/docs10gr3/operations/monitoring.html#wp1107685] (Looking at Figure 3-8)
The only way I could achieve this was to set the error handler stage to 'Reply with Failure' (which would return HTTP 500) ...
The issue however is that, the proprietory frontend simply sees the incoming HTTP 500 code and doesn't read the return XML payload (containing the error details ..)
which beats the whole idea of being able to maintain some sort of traceability for the failed transactions.
So what I'm basically trying to find is .. that when an error occurs
- Some 'call' to make the during the error handler stage so that it registers as an error in the OSB Service Health Page.. and I can clearly
see the error count, etc for each of the proxy services
- After that being able to still use 'Reply with Success' ... so that the payload is being returned with HTTP 500 code...
so the frontend can read the payload ...
............. in essence, the idea being to register errors so that they can be monitored via the Service Health Dashboard ..but at the same time
being able to return the 'error details' payload successfully
With my limited (but growing) knowledge of OSB .. I've tried quite a few ways to achieve this with no success...
Would very much appreciate any help here ...
Lastly, if there is some way of achieving what I'm trying to get to above through different means, I'm open
to trying out alternate stuff.
Regards,
HimanshuHi Atheek,
Many thanks for the reply. Does appear to be a pretty neat way of doing it ..
One more clarification I'd like on this however ....
Given that I have a set up like this below
[External frontend client] <------> (1 Parent Service) <------> (2 Child Service)
(1 Parent Service) .... has error handler .. and all it does is 'Reply with success'
(2 Child Service) .... has error handler for particular stage
so...
2 Child Service - is doing the actual work (has error handler where custom error msg is being populated in $body)
1 Parent Service - is the one that is getting called by the external client (has error handler .. and all it does is 'Reply with success')
What I currently have is ..once the error occurs, I'm populating $body ... with the custom error message within the error handler
Previously I had 'Reply with Success' in the 2 Child Service's error handler and the custom error message would get returned to the external client.
Now, with the error handler only creating the custom error msg.... and 1 Parent service doing the 'Reply with Success' .. it doesn't appear
to return the $body .. with the custom msg that I'd populated .. in 2 Child Service's error handler.
Are the $body contents populated in 2 Child Service's error handler lost ...once the error propagates up to 1 Parent service's error handler ?
If yes... is there way of getting around it ? I could see for instance that the $fault message context has a 'user populated' Details variable
but the documentation covering this is sparse.
Regards, -
Handling Transport Errors in OSB Proxy Services
Hi,
I have a requirement of storing and handling Transport level Security Errors in my proxy services . In fact, my proxy services are secured with HTTP Basic Authentication and i am not able to catch authentication errors. I added a Service Error Handler to my proxy service but unfortunatly it doesn't handle these errors.
Does anyone know how can we catch these errors in OSB, and if it is possible to execute activities like alerts, reports, logging in these cases.
I read in some blogs that Error handlers are nested like this : Route Node -> Proxy Service -> System Error Handler
so maybe it would be good to customize the System Error Handler Behavior. I don't know if this is possible.
Any help will be appreciated.
Best regards
FaroukTransport level authentication is done at transport layer even before the actual proxy service gets initiated. So you wont be able to catch authentication errors in the proxy service (and do alerting/logging/reporting etc). You can probably try enabling debug logging for HTTP protocol and see if you can capture these errors in the Access.log of the servers.
-
How to handle Oracle BLOBs with WebLogic 10.3
We have code that has been running for a long time to handle blobs in Oracle. We have never had a problem running inside of WebLogic, including WLS 10.0 and WLS 11. Recently, we had a customer that had a problem after they upgraded to WLS 10.3. Indeed, we downloaded that specific version and see the same issue. The issue is our Oracle db specific code is now causing an IllegalAccessException after we get the ResultSet vendor obj, by calling getVendorObj() on the WebLogic managed result set, and try to cast to an OracleResultSet. We need to do this in order to call OracleResultSet.getBLOB(), which returns an oracle.sql.BLOB. The code we use to update the blob is shown below. getOracleBLOB is our own method. It basically gets the OracleResultSet by calling getVendorObj on the managed WLS ResultSet, casting to an OracleResultSet, and calling getBLOB(colname) on it. Casting to the OracleResultSet causes the exception shown below. OK, so I understand WLS not wanting us to fiddle with the underlying db ResultSet, but what's our alternative. How can we do this without relying on the underlying OracleResultSet? After 10 years, working with many different versions of WebLogic as well as JBOSS and WebSphere, this is the first time we are seeing this.
Thanks in advance.
oracle.sql.BLOB blob = getOracleBLOB(rset,_columns.name);
OutputStream os = blob.getBinaryOutputStream();
ObjectOutputStream oos = new ObjectOutputStream(os);
oos.writeObject(_columns[i].paramObj);
oos.close();
java.rmi.RemoteException: EJB Exception: ; nested exception is:
javax.ejb.EJBException: nested exception is: javax.transaction.TransactionRolledbackException: Exception in ejbCreate(): java.lang.IllegalAccessError: tried to access class oracle.jdbc.driver.OracleResultSet from class com.armanta.ejb.gen.DefaultASHelper
at com.armanta.ejb.gen.DefaultASHelper.getOracleBLOB(DefaultASHelper.java:183)
at com.armanta.ejb.PreparedStatementWithBlobs.getOracleBLOB(PreparedStatementWithBlobs.java:180)
at com.armanta.ejb.PreparedStatementWithBlobs.executeUpdate(PreparedStatementWithBlobs.java:141)
at com.armanta.ejb.SimpleJDBCAbstractionWithBlobs.insert(SimpleJDBCAbstractionWithBlobs.java:57)
at com.armanta.ejb.ValueContainerBean.create(ValueContainerBean.java:230)
at com.armanta.ejb.tree.BranchBean.ejbCreate(BranchBean.java:42)
at com.armanta.ejb.tree.Branch_y1m5sk_Impl.ejbCreate(Branch_y1m5sk_Impl.java:255)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at weblogic.ejb.container.manager.ExclusiveEntityManager.create(ExclusiveEntityManager.java:775)
at weblogic.ejb.container.manager.ExclusiveEntityManager.remoteCreate(ExclusiveEntityManager.java:746)
at weblogic.ejb.container.internal.EntityEJBHome.create(EntityEJBHome.java:272)
at com.armanta.ejb.tree.Branch_y1m5sk_HomeImpl.create(Branch_y1m5sk_HomeImpl.java:79)
at com.armanta.ejb.tree.TreeMasterBean.addBranchesToTree(TreeMasterBean.java:430)
at com.armanta.ejb.tree.TreeMaster_n4wp5c_EOImpl.addBranchesToTree(TreeMaster_n4wp5c_EOImpl.java:800)
at com.armanta.ejb.tree.TreeMaster_n4wp5c_EOImpl_WLSkel.invoke(Unknown Source)
at weblogic.rmi.internal.BasicServerRef.invoke(BasicServerRef.java:589)
at weblogic.rmi.cluster.ClusterableServerRef.invoke(ClusterableServerRef.java:230)
at weblogic.rmi.internal.BasicServerRef$1.run(BasicServerRef.java:477)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:363)
at weblogic.security.service.SecurityManager.runAs(Unknown Source)
at weblogic.rmi.internal.BasicServerRef.handleRequest(BasicServerRef.java:473)
at weblogic.rmi.internal.wls.WLSExecuteRequest.run(WLSExecuteRequest.java:118)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
; nested exception is:
java.lang.IllegalAccessError: tried to access class oracle.jdbc.driver.OracleResultSet from class com.armanta.ejb.gen.DefaultASHelper
at weblogic.rjvm.BasicOutboundRequest.sendReceive(BasicOutboundRequest.java:108)
at weblogic.rmi.cluster.ReplicaAwareRemoteRef.invoke(ReplicaAwareRemoteRef.java:290)
at weblogic.rmi.cluster.ReplicaAwareRemoteRef.invoke(ReplicaAwareRemoteRef.java:247)
at com.armanta.ejb.tree.TreeMaster_n4wp5c_EOImpl_1030_WLStub.addBranchesToTree(Unknown Source)
at com.armanta.datamodel.EntityTreePool.addBranchesToTree(EntityTreePool.java:773)
at com.armanta.app.permission.MemberModel.add(MemberModel.java:233)
at com.armanta.app.permission.MemberPanel.actionPerformed(MemberPanel.java:248)
at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1849)
at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2169)
at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)
at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258)
at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:236)
at java.awt.Component.processMouseEvent(Component.java:5517)
at javax.swing.JComponent.processMouseEvent(JComponent.java:3135)
at java.awt.Component.processEvent(Component.java:5282)
at java.awt.Container.processEvent(Container.java:1966)
at java.awt.Component.dispatchEventImpl(Component.java:3984)
at java.awt.Container.dispatchEventImpl(Container.java:2024)
at java.awt.Component.dispatchEvent(Component.java:3819)
at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4212)
at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3892)
at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3822)
at java.awt.Container.dispatchEventImpl(Container.java:2010)
at java.awt.Window.dispatchEventImpl(Window.java:1791)
at java.awt.Component.dispatchEvent(Component.java:3819)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:463)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:242)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:163)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:157)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:149)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:110)
Caused by: javax.ejb.EJBException: nested exception is: javax.transaction.TransactionRolledbackException: Exception in ejbCreate(): java.lang.IllegalAccessError: tried to access class oracle.jdbc.driver.OracleResultSet from class com.armanta.ejb.gen.DefaultASHelper
at com.armanta.ejb.gen.DefaultASHelper.getOracleBLOB(DefaultASHelper.java:183)
at com.armanta.ejb.PreparedStatementWithBlobs.getOracleBLOB(PreparedStatementWithBlobs.java:180)
at com.armanta.ejb.PreparedStatementWithBlobs.executeUpdate(PreparedStatementWithBlobs.java:141)
at com.armanta.ejb.SimpleJDBCAbstractionWithBlobs.insert(SimpleJDBCAbstractionWithBlobs.java:57)
at com.armanta.ejb.ValueContainerBean.create(ValueContainerBean.java:230)
at com.armanta.ejb.tree.BranchBean.ejbCreate(BranchBean.java:42)
at com.armanta.ejb.tree.Branch_y1m5sk_Impl.ejbCreate(Branch_y1m5sk_Impl.java:255)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at weblogic.ejb.container.manager.ExclusiveEntityManager.create(ExclusiveEntityManager.java:775)
at weblogic.ejb.container.manager.ExclusiveEntityManager.remoteCreate(ExclusiveEntityManager.java:746)
at weblogic.ejb.container.internal.EntityEJBHome.create(EntityEJBHome.java:272)
at com.armanta.ejb.tree.Branch_y1m5sk_HomeImpl.create(Branch_y1m5sk_HomeImpl.java:79)
at com.armanta.ejb.tree.TreeMasterBean.addBranchesToTree(TreeMasterBean.java:430)
at com.armanta.ejb.tree.TreeMaster_n4wp5c_EOImpl.addBranchesToTree(TreeMaster_n4wp5c_EOImpl.java:800)
at com.armanta.ejb.tree.TreeMaster_n4wp5c_EOImpl_WLSkel.invoke(Unknown Source)
at weblogic.rmi.internal.BasicServerRef.invoke(BasicServerRef.java:589)
at weblogic.rmi.cluster.ClusterableServerRef.invoke(ClusterableServerRef.java:230)
at weblogic.rmi.internal.BasicServerRef$1.run(BasicServerRef.java:477)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:363)
at weblogic.security.service.SecurityManager.runAs(Unknown Source)
at weblogic.rmi.internal.BasicServerRef.handleRequest(BasicServerRef.java:473)
at weblogic.rmi.internal.wls.WLSExecuteRequest.run(WLSExecuteRequest.java:118)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
; nested exception is:
java.lang.IllegalAccessError: tried to access class oracle.jdbc.driver.OracleResultSet from class com.armanta.ejb.gen.DefaultASHelper
at com.armanta.ejb.tree.TreeMasterBean.addBranchesToTree(TreeMasterBean.java:442)
at com.armanta.ejb.tree.TreeMaster_n4wp5c_EOImpl.addBranchesToTree(TreeMaster_n4wp5c_EOImpl.java:800)
at com.armanta.ejb.tree.TreeMaster_n4wp5c_EOImpl_WLSkel.invoke(Unknown Source)
at weblogic.rmi.internal.BasicServerRef.invoke(BasicServerRef.java:589)
at weblogic.rmi.cluster.ClusterableServerRef.invoke(ClusterableServerRef.java:230)
at weblogic.rmi.internal.BasicServerRef$1.run(BasicServerRef.java:477)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:363)
at weblogic.security.service.SecurityManager.runAs(Unknown Source)
at weblogic.rmi.internal.BasicServerRef.handleRequest(BasicServerRef.java:473)
at weblogic.rmi.internal.wls.WLSExecuteRequest.run(WLSExecuteRequest.java:118)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)We ultimately found out what the issue was. Turns out that OracleResultSet moved from oracle.jdbc.driver into oracle.jdbc starting with ojdbc6.jar. We were referencing the oracle.jdbc.driver package.
-
Handling Special characters in OSB
Hi All,
We are using OSB with weblogic 11g in our Project. We found a strange behavior while fetching the data from DB using DB adapter.
For few records in DB, we are having & and few other special characters. While fetching the data:
• If the content length is greater than “38” for a particular field which contains special characters, we are able to process it successfully (Data Comes as “&” for “&” in XML from DB)
• If content length is less than “38”, “&” appears same without “amp;”
Please let me know if anyone have faced a similar issue. We would like to have "&" or "&", Only one and not both irrespective of the content length.
Any Clue would be of great help.
Regards
Srikar SreeramThanks for your reply vlad.
When i mean OSB, it is ALSB which was aquired by oracle and named as OSB.
We have two records in Data base with '&'. when we picked both the records using DB adapter, one records is coming with "&" and other with "&".
To identify the issue in more detail, we tried to increase the length of the record by adding some extra normal characters and tested thoroughtly. At one point exactly when the length is >= 38, we found the records coming with "&". Similar behavior was observed in differnt DB's.
Sample Data:
"Asia Pac|China & Hong Kong|3J|Other Indochina| "
"Asia Pac|China & Hong Kong|CN|China| "
Not sure if this requires any weblogic level configurations/ or any other adapter level configurations so that data comes with "&"
We have defined the field in DB as Varchar2 (2000) and Please find below DB schema:
<?xml version = '1.0' encoding = 'UTF-8'?>
<xs:schema targetNamespace="http://xmlns.oracle.com/pcbpel/adapter/db/ExecAppSettingsFeedService" xmlns="http://xmlns.oracle.com/pcbpel/adapter/db/ExecAppSettingsFeedService" elementFormDefault="qualified" attributeFormDefault="qualified" xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xs:element name="ExecAppSettingsFeedServiceInput" type="ExecAppSettingsFeedServiceInput"/>
<xs:complexType name="ExecAppSettingsFeedServiceInput">
<xs:sequence>
<xs:element name="LastRefreshDate" type="xs:string" nillable="true"/>
</xs:sequence>
</xs:complexType>
<xs:element name="ExecAppSettingsFeedServiceOutputCollection" type="ExecAppSettingsFeedServiceOutputCollection"/>
<xs:complexType name="ExecAppSettingsFeedServiceOutputCollection">
<xs:sequence>
<xs:element name="ExecAppSettingsFeedServiceOutput" type="ExecAppSettingsFeedServiceOutput" minOccurs="0" maxOccurs="unbounded"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="ExecAppSettingsFeedServiceOutput">
<xs:sequence>
<xs:element name="record_type" type="xs:decimal" nillable="true"/>
<xs:element name="RECORD_VALUE" type="xs:string" nillable="true"/>
<xs:element name="LAST_UPDATED_DATE" type="xs:dateTime" nillable="true"/>
</xs:sequence>
</xs:complexType>
</xs:schema> -
How to handle multiRef responses in OSB 10.3???
We are using OSB 10.3 version.
I am getting difficulty to get the multiRef soap response in the Service Callout*:
When I check the SBConsole Invocation Trace the whole response body is appearing in business service but returning part of the response.
Its missing the multiRef as below:
<ns4:getProductServiceRequestForUserResponse soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:ns4="abc:ProductManagementService">
<getProductServiceRequestForUserReturn href="#id0"/>
</ns4:getProductServiceRequestForUserResponse>
It should return
<soapenv:Body>
<ns4:getProductServiceRequestForUserResponse soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:ns4="abc:ProductManagementService">
<getProductServiceRequestForUserReturn href="#id0"/>
</ns4:getProductServiceRequestForUserResponse>
<multiRef id="id0" soapenc:root="0" soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xsi:type="ns5:ProductLinkRequest"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:ns5="http://ato.domain.services.abc.com">
<id xsi:type="xsd:long">3068</id>
<requestStatus href="#id1"/>
<modifiedDate xsi:type="xsd:dateTime">2009-06-23T01:22:02.000Z</modifiedDate>
<prd xsi:type="xsd:string">249249</prd>
<serviceNo href="#id2"/>
<statusReason xsi:type="xsd:string">Delivery completed</statusReason>
</multiRef>
</soapenv:Body>
After Service Callout, I have tried to assign the reponse to valriable but it returns missing multiRef
$body/multiRef
Any suggestions??
Thank you
Edited by: user11310683 on Sep 1, 2011 5:20 AM
Edited by: user11310683 on Sep 2, 2011 2:48 PMGetting difficulty to use Java Callout.
I have written my java class to call webservice and kept all necessary jars in the lib with MANIFEST file.
I kept all my jars in project/Resources/JAR/*.jar and included all dependency jar to my generated jar.
But the Java Callout is thowing java.lang.NoClassDefFoundError: javax/wsdl/OperationType
at org.apache.axis.description.OperationDesc.<clinit>(OperationDesc.java:59)
Its working fine when I copied all jars in user_project/domains/proj_domain/lib.
But I don't want to put all my jars at user_project/domains/proj_domain/lib. -
How can i put a file into blob(using sun.jdbc.odbc.JdbcOdbcDriver)
Hi
i tried to put a file into blob , but got a problem.....
My environment:windows 2000pro,JBuilder 5.0 enterprise,oracle 8.1.6,(not install oracle jdbc driver )
a part of program(my program is very uglily,if anyone want,later i paste it ba....~_~)
//Statement stmt2=null;
//Resultset rs2;
//opa1 is the blob data
void saveBlobTableToDisk(Connection con) {
try {
stmt2=con.createStatement();
sqlStr2="SELECT * FROM emp3 where id=1004";
rs2=stmt2.executeQuery(sqlStr2);
while (rs2.next()) {
Blob aBlob=rs2.getBlob("opa1");
i got the exception :
" null
java.lang.UnsupportedOperationException
at sun.jdbc.odbc.JdbcOdbcResultSet.getBlob(JdbcOdbcResultSet.java:4174)
at test3.Frame1.saveBlobTableToDisk(Frame1.java:48)
at test3.Frame1.<init>(Frame1.java:26)
at test3.Application1.<init>(Application1.java:5)
at test3.Application1.main(Application1.java:8) "
and the windows pop up a messagebox said that(about) my memory "0x09af007f" could not read, error in javaw.exe .
Later i used (ResultSet)getBinaryStream() to solve it. but getBinaryStream() only return a InputStream,so that i can make blob to a file,but i can't make a file to blob using jdbc.....
I am very stupid that installing sun java, oracle jdbc driver etc....(because i must set a lot of thing such as classpath,java_home etc), Can i only use JBuilder to do that ?
Or i must install oracle jdbc driver ?
Thanks.My guess here is that Sun's JDBC-ODBC bridge doesn't handle the BLOB datatype. Most ODBC drivers don't support that datatype, so I wouldn't expect the bridge to.
Is there a reason that you can't use the Oracle driver?
Justin -
How can i put a file into blob using jdbc !?
Hi
i tried to put a file into blob , but got a problem.....
My environment:windows 2000pro,JBuilder 5.0 enterprise,oracle 8.1.6,(not install oracle jdbc driver )
a part of program(my program is very uglily,if anyone want,later i paste it ba....~_~)
//Statement stmt2=null;
//Resultset rs2;
//opa1 is the blob data
void saveBlobTableToDisk(Connection con) {
try {
stmt2=con.createStatement();
sqlStr2="SELECT * FROM emp3 where id=1004";
rs2=stmt2.executeQuery(sqlStr2);
while (rs2.next()) {
Blob aBlob=rs2.getBlob("opa1");
i got the exception :
" null
java.lang.UnsupportedOperationException
at sun.jdbc.odbc.JdbcOdbcResultSet.getBlob(JdbcOdbcResultSet.java:4174)
at test3.Frame1.saveBlobTableToDisk(Frame1.java:48)
at test3.Frame1.<init>(Frame1.java:26)
at test3.Application1.<init>(Application1.java:5)
at test3.Application1.main(Application1.java:8) "
and the windows pop up a messagebox said that(about) my memory "0x09af007f" could not read, error in javaw.exe .
Later i used (ResultSet)getBinaryStream() to solve it. but getBinaryStream() only return a InputStream,so that i can make blob to a file,but i can't make a file to blob using jdbc.....
I am very stupid that installing sun java, oracle jdbc driver etc....(because i must set a lot of thing such as classpath,java_home etc), Can i only use JBuilder to do that ?
Or i must install oracle jdbc driver ?
Thanks.
D.T.My guess here is that Sun's JDBC-ODBC bridge doesn't handle the BLOB datatype. Most ODBC drivers don't support that datatype, so I wouldn't expect the bridge to.
Is there a reason that you can't use the Oracle driver?
Justin -
Hi,
We have created a JMS Queue in WLS 10.3.0 and OSB (10.3.1) process is using proxy service - JMS transport to dequeue messages.
WLS JMS Queue -->OSB Proxy --> Business Service (JCA Db adapter) to insert data into a table
IF error in db --> Invoke OSB error handler and write to a file
Case - Success
Messages are deleted from the queue
Case - Failure
Messages are not deleted from the queue. Error handler is invoked in OSB and messages are written to a file.
This is creating an issue since OSB retries and number of files are created. We have tried setting retry settings in OSB, but in vain.
Please provide inputs, this is a bit of emergency.
Regards,
AP
Edited by: ARPL on Oct 15, 2009 3:41 AMAm also dumb...
You need to create a new proxy service (and select the message type which suits your process, anysoap any xml, wsdl, etc), on the second tab you can select the transport.
In here select jms from the listbox and for the endpoint insert "jms://yourhost:yourpost/yourconnectionfactory/yourqueue"
thats all what is needed to let your proxy service pick up the messages from the queue.
eventually you want to route this message to something else, so for that you need to decide what sort of business service you use (webservice wsdl based, or just some other jms endpoint,or file...you name it)
@@JMS implementation in OSB
OSB concepts are really hard to digest if u r SOA developer from start. Proxy Service will act as a Inbound for JMS. It still shows the "Destination type" in JMS Transport Config tab
Really Confussing....
Sushil
Edited by: Sushil Deshpande on Jan 26, 2011 2:22 AM -
Oracle Blob using Java help (Error: JVM_recv in socket input stream read )
I am trying to insert a record with Blob column (size of image 'mg.jpg' about 15KB) and I get the runtime error:
[java] java.sql.SQLException: Io exception: Connection reset by peer: JVM_recv in socket input stream read
[java] at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
[java] at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:179)
[java] at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:333)
[java] at oracle.jdbc.driver.OracleStatement.executeNonQuery(OracleStatement.java:2061)
[java] at oracle.jdbc.driver.OracleStatement.doExecuteOther(OracleStatement.java:1940)
[java] at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:2709)
[java] at oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedStatement.java:589)
[java] at test.ProvisioningParser.TestBlob.main(Unknown Source)
This is what code looks like: I am not sure what's wrong, any help appreciated. Thanks!
try{
Class.forName("oracle.jdbc.driver.OracleDriver");
con = DriverManager.getConnection("jdbc:oracle:thin:@VALUED-20606295:1521:dbbook","jvending","jvending");
java.util.zip.ZipInputStream zip = new java.util.zip.ZipInputStream(new java.io.FileInputStream(new java.io.File("D:\\work\\mywork\\source\\test\\ProvisioningParser\\test.par"))) ;
int len = 0 ;
java.util.zip.ZipEntry entry = null;
do{
entry = zip.getNextEntry();
if (entry != null){
if (entry.getName().equalsIgnoreCase("mg.jpg")){
len = (int)entry.getSize();
break;
}while(entry!=null) ;
stmt = con.prepareStatement( "Insert into icon (parid, clientbundleid, id, iconfile ) values ( ?,?,?,?)"
stmt.setString(1,"101");
stmt.setString(2,"101");
stmt.setInt(3,1);
stmt.setBinaryStream( 4, zip, len);
stmt.setQueryTimeout(0);
stmt.executeUpdate();
con.close();
catch(Exception e){
e.printStackTrace();
}Thanks,
RashmiAs a guess what you are doing with that zip stuff is very odd.
You do realize that it is just going to put some binary data into the blob right? And the methods that is going to use will not necessarily create a 'complete' zip file?
If you want a zip file then just load the file, dont use the zip classes.
And if you want part of a zip file, (and want to store the parts as a zip) then extract it from the file and create another zip entity using a byte stream rather than a file.
Finally I suspect your error with the blob occurs because you do not close the statement. But at any rate you should figure out how to do the blob code independent of the zip stuff.
And what oracle driver version are you using? Some of the older ones need oracle specific handling for blobs. -
Slow performance of fetching BLOB data over network is very slow
Dear Experts,
We are deploying a GIS application which handles with BLOB datatypes. Database Server is in RHEL and in 11gR2. The application is using asp.net 3.5 and using ODP.NET to connect with Oracle. But here is a performance chart which shows that performance is very slow when application and database server lie on different subnetwork.
Case Login Time
Same Server(Both in 192.168.9.23) 20-25 sec
Same Subnet (DB:192.168.9.25) (App: 192.168.9.23) 60-80 sec
Different Subnet (DB:192.168.11.153) (App:192.168.9.23) More then 5 minutes
So what is the reason behind this and how can I improve performance if I want to keep application and database in diff machine?
Thanks in advance.Also, look into the various lob settings in ODP.NET.
I believe that by default in ODP.NET the LOB will be fetched in separate roundtrips but you can change this my messing with certain properties or using certain methods - apologies, a bit imprecise.
If you have a network issue then doing more roundtrips than you need to is just going to exacerbate the situation.
Trace the session - if it's networking or roundtrips you should see symptoms of it in a 10046 trace. -
ClassCastException w/ BLOB
We are currently using v 2.5.2 and have run into a problem when attempting
to insert a BLOB using WebLogic (via EJB). When I run a stand-alone test
case, everything works as planned. The BLOB is inserted with no problems.
However, if I change the test case to call an EJB deployed on WebLogic
8.1 (which in turn calls the same functionality to insert the BLOB via
KODO), a receive the following exception:
NestedThrowablesStackTrace:
java.lang.ClassCastException
at
com.solarmetric.kodo.impl.jdbc.ormapping.OracleBlobMapping.update(OracleBlobMapping.java:100)
at
com.solarmetric.kodo.impl.jdbc.ormapping.OracleBlobMapping.insert(OracleBlobMapping.java:73)
at
com.solarmetric.kodo.impl.jdbc.ormapping.ClassMapping.insert(ClassMapping.java:437)
at
com.solarmetric.kodo.impl.jdbc.runtime.JDBCStoreManager.flush(JDBCStoreManager.java:530)
at
com.solarmetric.kodo.runtime.PersistenceManagerImpl.flushInternal(PersistenceManagerImpl.java:697)
at
com.solarmetric.kodo.runtime.PersistenceManagerImpl.commit(PersistenceManagerImpl.java:422)
at
com.iits.sdb.app.facade.MaintainProducerRequestFacade.addProducerRequest(MaintainProducerRequestFacade.java:99)
at
com.iits.sdb.app.delegate.MaintainProducerRequestDelegate.addProducerRequest(MaintainProducerRequestDelegate.java:89)
at
com.iits.ejb.RequestProcessBean.persistRequest(RequestProcessBean.java:333)
at
com.iits.ejb.RequestProcessBean.prepareAddInitialAppointment(RequestProcessBean.java:125)
at
com.iits.ejb.RequestProcessEjb_pfomyb_EOImpl.prepareAddInitialAppointment(RequestProcessEjb_pfomyb_EOImpl.java:150)
at
com.iits.ejb.RequestProcessEjb_pfomyb_EOImpl_WLSkel.invoke(Unknown Source)
at
weblogic.rmi.internal.BasicServerRef.invoke(BasicServerRef.java:466)
at
weblogic.rmi.cluster.ReplicaAwareServerRef.invoke(ReplicaAwareServerRef.java:108)
at
weblogic.rmi.internal.BasicServerRef$1.run(BasicServerRef.java:409)
at
weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:353)
at
weblogic.security.service.SecurityManager.runAs(SecurityManager.java:144)
at
weblogic.rmi.internal.BasicServerRef.handleRequest(BasicServerRef.java:404)
at
weblogic.rmi.internal.BasicExecuteRequest.execute(BasicExecuteRequest.java:30)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:197)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:170)
Any help would be greatly appreciated.Marc,
After doing some additional investigation, the following link provides
more insight into why the error occurred.
http://e-docs.bea.com/wls/docs70/jdbc/thirdparty.html#1045809
It seems like adding a conditional cast to weblogic's wrapper class,
weblogic.jdbc.vendor.oracle.OracleThinBlob, would fix the issue in
OracleBlobMapping. Is there a recommended way for us to add this
functionality, to enable us to still use Kodo for BLOB's in WebLogic?
Thanks,
Josh
Josh Zook wrote:
After trying your suggestion below, I still run into the same issue (see
stack trace below). However, after looking at the generated SQL, it
appears that Kodo is trying to INSERT the blob, rather than use
EMPTY_BLOB() and then SELECT FOR UPDATE. I don't think upgrading is 3.0
is an option for us at this time. Please let me know if you can think of
anything else.
Thanks,
Josh
java.sql.SQLException: Data size bigger than max size for this type: 4036
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:179)
at oracle.jdbc.ttc7.TTCItem.setArrayData(TTCItem.java:95)
at
oracle.jdbc.dbaccess.DBDataSetImpl.setBytesBindItem(DBDataSetImpl.java:2413)
at
oracle.jdbc.driver.OraclePreparedStatement.setItem(OraclePreparedStatement.java:1166)
at
oracle.jdbc.driver.OraclePreparedStatement.setBinaryStream(OraclePreparedStatement.java:2598)
at
weblogic.jdbc.wrapper.PreparedStatement.setBinaryStream(PreparedStatement.java:289)
at
com.iits.pulsar.jdo.OracleDictionary.blobToPreparedParameter(OracleDictionary.java:76)
Marc Prud'hommeaux wrote:
Josh-
The problem is that the Oracle JDBC drivers require special handling for
blobs over a certain size: they need to have Oracle-specific BLOB/CLOB
classes. Unfortunately, when another DataSource wraps the oracle
DataSource, there isn't much we can do.
Kodo 3.0 has a better way of doing this that will probably work around
your problem. If you don't want to upgrade to 3.0 RC 1, then you
could try to subclass OracleDictionary with your own class that
overrides AbstractDictionary.blobToPreparedParameter. I have read that
some versions of the Oracle driver will handle a direct blob better if
you call stmnt.setBinaryStream(index, new ByteArrayInputStram (bytes))
the if you do stmnt.setObject(index, ob) (which is the default way we
deal with this).
Please let us know if you still have problems after trying this.
In article <[email protected]>, Josh Zook wrote:
Thanks for the help. Yes, we are using WebLogic datasource, so that is
the root of the problem. My standalone test case was using Kodo intenal
connection pooling. It looks like WebLogic datasource wraps the
ResultSet
and Blob in it's own classes (perhaps causing the cast exception?).
I tried you advice and set isOracleJDBCDriver=false. I now get the
exception listed below. Any suggestions would be appreciated.
java.sql.SQLException: Data size bigger than max size for this type: 4009
atoracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
atoracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:179)
at oracle.jdbc.ttc7.TTCItem.setArrayData(TTCItem.java:95)
at
oracle.jdbc.dbaccess.DBDataSetImpl.setBytesBindItem(DBDataSetImpl.java:2413)
at
oracle.jdbc.driver.OraclePreparedStatement.setItem(OraclePreparedStatement.java:1166)
at
oracle.jdbc.driver.OraclePreparedStatement.setBytes(OraclePreparedStatement.java:2208)
at
oracle.jdbc.driver.OraclePreparedStatement.setObject(OraclePreparedStatement.java:3002)
at
oracle.jdbc.driver.OraclePreparedStatement.setObject(OraclePreparedStatement.java:3217)
at
weblogic.jdbc.wrapper.PreparedStatement.setObject(PreparedStatement.java:172)
at
com.solarmetric.kodo.impl.jdbc.schema.dict.AbstractDictionary.blobToPreparedParameter(AbstractDictionary.java:1110)
at
com.solarmetric.kodo.impl.jdbc.schema.dict.OracleDictionary.blobToPreparedParameter(OracleDictionary.java:203)
at
com.solarmetric.kodo.impl.jdbc.schema.dict.AbstractDictionary.toPreparedParameter(AbstractDictionary.java:840)
at
com.solarmetric.kodo.impl.jdbc.sql.SQLValue.applyParameter(SQLValue.java:129)
at
com.solarmetric.kodo.impl.jdbc.sql.SQLBuffer.setParameters(SQLBuffer.java:239)
at
com.solarmetric.kodo.impl.jdbc.sql.SQLBuffer.setParameters(SQLBuffer.java:222)
at
com.solarmetric.kodo.impl.jdbc.SQLExecutionManagerImpl.prepareStatementInternal(SQLExecutionManagerImpl.java:753)
at
com.solarmetric.kodo.impl.jdbc.SQLExecutionManagerImpl.executePreparedStatementNonBatch(SQLExecutionManagerImpl.java:445)
at
com.solarmetric.kodo.impl.jdbc.SQLExecutionManagerImpl.executePreparedStatement(SQLExecutionManagerImpl.java:423)
at
com.solarmetric.kodo.impl.jdbc.SQLExecutionManagerImpl.executeInternal(SQLExecutionManagerImpl.java:381)
at
com.solarmetric.kodo.impl.jdbc.SQLExecutionManagerImpl.flush(SQLExecutionManagerImpl.java:255)
at
com.solarmetric.kodo.impl.jdbc.runtime.JDBCStoreManager.flush(JDBCStoreManager.java:554)
at
com.solarmetric.kodo.runtime.PersistenceManagerImpl.flushInternal(PersistenceManagerImpl.java:697)
at
com.solarmetric.kodo.runtime.PersistenceManagerImpl.commit(PersistenceManagerImpl.java:422)
at
com.iits.sdb.app.facade.MaintainProducerRequestFacade.addProducerRequest(MaintainProducerRequestFacade.java:106)
>>>
>>>
Marc Prud'hommeaux wrote:
Josh-
Are you using Kodo's own DataSource in the Weblogic environment, or are
you using a DataSource bound into WebLogic's JNDI? If the latter, then
it may be that our special blob handling for Oracle is having problems
with WebLogic's DataSource.
One thing you might try to do is set the DictionaryProperties to have
"isOracleJDBCDriver=false", which should prevent Kodo from using it's
special Oracle driver behavior.
In article <[email protected]>, Josh Zook wrote:
We are currently using v 2.5.2 and have run into a problem when
attempting
to insert a BLOB using WebLogic (via EJB). When I run a stand-alonetest
case, everything works as planned. The BLOB is inserted with noproblems.
However, if I change the test case to call an EJB deployed on
WebLogic
8.1 (which in turn calls the same functionality to insert the BLOB via
KODO), a receive the following exception:
NestedThrowablesStackTrace:
java.lang.ClassCastException
at
com.solarmetric.kodo.impl.jdbc.ormapping.OracleBlobMapping.update(OracleBlobMapping.java:100)
at
com.solarmetric.kodo.impl.jdbc.ormapping.OracleBlobMapping.insert(OracleBlobMapping.java:73)
at
com.solarmetric.kodo.impl.jdbc.ormapping.ClassMapping.insert(ClassMapping.java:437)
at
com.solarmetric.kodo.impl.jdbc.runtime.JDBCStoreManager.flush(JDBCStoreManager.java:530)
at
com.solarmetric.kodo.runtime.PersistenceManagerImpl.flushInternal(PersistenceManagerImpl.java:697)
at
com.solarmetric.kodo.runtime.PersistenceManagerImpl.commit(PersistenceManagerImpl.java:422)
at
com.iits.sdb.app.facade.MaintainProducerRequestFacade.addProducerRequest(MaintainProducerRequestFacade.java:99)
at
com.iits.sdb.app.delegate.MaintainProducerRequestDelegate.addProducerRequest(MaintainProducerRequestDelegate.java:89)
at
com.iits.ejb.RequestProcessBean.persistRequest(RequestProcessBean.java:333)
at
com.iits.ejb.RequestProcessBean.prepareAddInitialAppointment(RequestProcessBean.java:125)
at
com.iits.ejb.RequestProcessEjb_pfomyb_EOImpl.prepareAddInitialAppointment(RequestProcessEjb_pfomyb_EOImpl.java:150)
at
com.iits.ejb.RequestProcessEjb_pfomyb_EOImpl_WLSkel.invoke(UnknownSource)
at
weblogic.rmi.internal.BasicServerRef.invoke(BasicServerRef.java:466)
at
weblogic.rmi.cluster.ReplicaAwareServerRef.invoke(ReplicaAwareServerRef.java:108)
at
weblogic.rmi.internal.BasicServerRef$1.run(BasicServerRef.java:409)
at
weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:353)
at
weblogic.security.service.SecurityManager.runAs(SecurityManager.java:144)
at
weblogic.rmi.internal.BasicServerRef.handleRequest(BasicServerRef.java:404)
at
weblogic.rmi.internal.BasicExecuteRequest.execute(BasicExecuteRequest.java:30)
atweblogic.kernel.ExecuteThread.execute(ExecuteThread.java:197)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:170)
Any help would be greatly appreciated.
Marc Prud'hommeaux [email protected]
SolarMetric Inc. http://www.solarmetric.com
Marc Prud'hommeaux [email protected]
SolarMetric Inc. http://www.solarmetric.com -
ORA-24810 on writing blob via Pro*C
I'm using Oracle Pro*C with an Oracle 9.2 RDBMS.
I am trying to store a blob from a file using Pro*C. If the file is small enough that I can read/write the entire file in a single operation, it blow write works okay. However, I would like to be able to handle a blob of any size, up to 4MB. Unless, I use a 4MB io buffer, this requires partial file read / blob writes. In the program before, the initial write (first) works, but subsequent writes (next) fail with the 24810 attempting to write more data than indicated error. I cannot find a worthwhile explanation for this error - what does it mean?
Here is my sample program.
#include <oci.h>
#include <stdio.h>
#define CMN_IO_BUFF_SIZE 4096
EXEC SQL INCLUDE sqlca.h;
EXEC SQL INCLUDE oraca.h;
EXEC SQL BEGIN DECLARE SECTION;
VARCHAR f_Conn[100];
EXEC SQL END DECLARE SECTION;
int main () {
OCIBlobLocator *DbBlob;
FILE *Fp;
int FirstRead;
unsigned int BytesRead;
unsigned int Offset;
unsigned char IoBuff[CMN_IO_BUFF_SIZE];
strcpy ( f_Conn.arr, "isis_app/isis_app@isisdev1" );
f_Conn.len = strlen ( f_Conn.arr );
EXEC SQL VAR IoBuff IS RAW ( CMN_IO_BUFF_SIZE );
printf ( "VAR returned error %d\n", sqlca.sqlcode );
printf ( " %s\n", sqlca.sqlerrm.sqlerrmc );
EXEC SQL CONNECT :f_Conn;
printf ( "CONNECT returned error %d\n", sqlca.sqlcode );
printf ( " %s\n", sqlca.sqlerrm.sqlerrmc );
EXEC SQL ALLOCATE :DbBlob;
printf ( "ALLOC returned error %d\n", sqlca.sqlcode );
printf ( " %s\n", sqlca.sqlerrm.sqlerrmc );
EXEC SQL INSERT INTO lob_table (a_blob)
VALUES (EMPTY_BLOB())
RETURNING a_blob INTO :DbBlob;
printf ( "INSERT returned error %d\n", sqlca.sqlcode );
printf ( " %s\n", sqlca.sqlerrm.sqlerrmc );
Fp = fopen ( "test.gif", "r" );
if ( Fp != 0 ) {
FirstRead = 1;
Offset = 1;
BytesRead = CMN_IO_BUFF_SIZE;
while ( BytesRead > 0 ) {
printf ( "Bytes requested %d\n", BytesRead );
BytesRead = fread ( IoBuff, 1, BytesRead, Fp );
printf ( "Bytes read %d\n", BytesRead );
if ( ( FirstRead == 1 ) && ( BytesRead < CMN_IO_BUFF_SIZE ) ) {
EXEC SQL LOB WRITE ONE :BytesRead
FROM :IoBuff INTO :DbBlob AT :Offset;
printf ( "WRITE ONE returned error %d\n", sqlca.sqlcode );
printf ( " %s\n", sqlca.sqlerrm.sqlerrmc );
printf ( "Bytes written %d at offset %d\n", BytesRead, Offset );
} else if ( ( FirstRead == 1 ) && ( BytesRead == CMN_IO_BUFF_SIZE ) ) {
EXEC SQL LOB WRITE FIRST :BytesRead
FROM :IoBuff INTO :DbBlob AT :Offset;
printf ( "WRITE FIRST returned error %d\n", sqlca.sqlcode );
printf ( " %s\n", sqlca.sqlerrm.sqlerrmc );
printf ( "Bytes written %d at offset %d\n", BytesRead, Offset );
} else if ( ( FirstRead == 0 ) && ( BytesRead == CMN_IO_BUFF_SIZE ) ) {
EXEC SQL LOB WRITE NEXT :BytesRead
FROM :IoBuff INTO :DbBlob AT :Offset;
printf ( "WRITE NEXT returned error %d\n", sqlca.sqlcode );
printf ( " %s\n", sqlca.sqlerrm.sqlerrmc );
printf ( "Bytes written %d at offset %d\n", BytesRead, Offset );
} else if ( ( FirstRead == 0 ) && ( BytesRead < CMN_IO_BUFF_SIZE ) ) {
EXEC SQL LOB WRITE LAST :BytesRead
FROM :IoBuff INTO :DbBlob AT :Offset;
printf ( "WRITE LAST returned error %d\n", sqlca.sqlcode );
printf ( " %s\n", sqlca.sqlerrm.sqlerrmc );
printf ( "Bytes written %d at offset %d\n", BytesRead, Offset );
FirstRead = 0;
Offset = Offset + BytesRead;
if ( BytesRead < CMN_IO_BUFF_SIZE ) {
BytesRead = 0;
fclose ( Fp );
} else {
printf ( "Error opening input file\n" );
EXEC SQL COMMIT WORK;
printf ( "COMMIT returned error %d\n", sqlca.sqlcode );
printf ( " %s\n", sqlca.sqlerrm.sqlerrmc );
}Do not use buffered IO (FILE*) . Use direct Calls(Open/Write).
Buffered IO has limiations -
RESTful Service Module and Blob column
Hi
I created Restful as GET with some parameters. Everythink works without blob column. When I run restful handler in blob column i had "...binary data omitted...". Is some solution to catch file from APEX web service ?
APEX 4.2.2 on Listener 2.1 or 2.2
RegardsHi,
You cannot use Blobs directly as fields in CMP EJB, since Blob is really an open cursor to the database, and it is not serializable.
Here's a How-to on using Blobs
http://otn.oracle.com/tech/java/oc4j/904/content_preview.html
You can see the code for this at the end of the page
http://otn.oracle.com/tech/java/oc4j/904/how_to/how-to-ejb-cmpblob.zip
Hope this helps,
Thanks,
Neelesh
OTN Team @ IDC
Maybe you are looking for
-
Where can i download iPhoto 9.5
where can i download iPhoto 9.5 The apple downloader says that I have iPhoto installed but I need the old version
-
I had this problem before. The video clips in a menu will not play in the simulator or on the created DVD. To fix the problem a certain file (maybe a preference file) had to be thrown away. I can not remember what file that is. Does anyone know its n
-
Has anyone been successful on a pool creation with using KMS?... I have tried with ISO and existing VM. Main reason I ask is that when I tried using a MAK key after a while the pool vms became not activated which eventually became not geniune. Whic
-
Need full photo dump to external HD or cloud
My iPhone is choking with photos. Most have been downloaded but I might have missed some, and many of them are important to me. Is there any way to download the whole lot of them directly to an external hard drive? My internal hard drive is running o
-
How to get rowcount of VO on .vm file?
how to get rowcount of VO on .vm file?