Clob issue
Hi, I'm on the latest version of Apex on Oracle 11gr2
I have a function which returns a clob. Basically just a string which dynamically builds a load of html , divs etc in it.
In my page I call the function using ajax callback.
Depending upon the size of the clob returned by the function I get the following error message sqlerrm:ORA-06502: PL/SQL: numeric or value error
So a size based on length(clob) of 2861 works but one of 141486 gives the error. I appreciate there is a considerable difference in the 2 values but neither are anywhere near 4G for a clob.
I hav'nt a clue how to resolve this
Ed.
Hi, I'm on the latest version of Apex on Oracle 11gr2I have a function which returns a clob. Basically just a string which dynamically builds a load of html , divs etc in it.
In my page I call the function using ajax callback.
Depending upon the size of the clob returned by the function I get the following error message sqlerrm:ORA-06502: PL/SQL: numeric or value error
So a size based on length(clob) of 2861 works but one of 141486 gives the error. I appreciate there is a considerable difference in the 2 values but neither are anywhere near 4G for a clob.
I hav'nt a clue how to resolve this
>
If you are returning HTML fragment then you need to have a CRLF at least every 4000 character. That is the HTML Spec.
If you are trying to store the returned CLOB in a Page or Application Item then you are hitting the 32K limit. If that is the case then try return the CLOB (rather array of VARCHAR2) from an On Demand Process with HTP.P
Cheers,
Similar Messages
-
DBMS_LOB Package for CLOB Issues
I was wondering if any of you have worked with DBMS_LOB
packages. I wrote a procedure that will be invoked from a 'C'
program. I was first compiling the procedure as follows:
procedure <procedurename> (c_text out char, length in number)
declare c_lob CLOB;
begin
SELECT lob_locator_column into c_lob from <table>
WHERE
<table>.id = '1';
dbms_lob.read(c_lob,length,1,c_text)
end;
When I compile this program I am getting an error "length cannot
be used as a target". Have any of you seen this problem?
Right now I am getting around by declaring another variable and
assigning the input length to the variable and passing it into
DBMS_LOB.
Another issue I have is that the DBMS package is returning the
length of the clob to be an "INTEGER". What happens if the clob
length is greater than 32767?
nullI guess you are using a reserved word..
Bala Vanukuru (guest) wrote:
: I was wondering if any of you have worked with DBMS_LOB
: packages. I wrote a procedure that will be invoked from a 'C'
: program. I was first compiling the procedure as follows:
: procedure <procedurename> (c_text out char, length in number)
: declare c_lob CLOB;
: begin
: SELECT lob_locator_column into c_lob from <table>
: WHERE
: <table>.id = '1';
: dbms_lob.read(c_lob,length,1,c_text)
: end;
: When I compile this program I am getting an error "length
cannot
: be used as a target". Have any of you seen this problem?
: Right now I am getting around by declaring another variable
and
: assigning the input length to the variable and passing it into
: DBMS_LOB.
: Another issue I have is that the DBMS package is returning the
: length of the clob to be an "INTEGER". What happens if the
clob
: length is greater than 32767?
null -
String Literal too long / CLOB Issue
I have a table with a "Clob" column called Message. This is where I store the message of an email. We have an internal email app. What is happening is I can't insert anything bigger then around 3990 or something around there. In my procedure I have the parameter coming in as clob and I use a TO_CHAR() around the table column and my parameter or my procedure gives me this error
PL/SQL: ORA-00932: inconsistent datatypes: expected - got CLOB
But when it runs and I put in a 9000 character message it says
Oracle.DataAccess.Client.OracleException was unhandled by user code
Message="ORA-01704: string literal too long
I'm using C# with
Oracle.DataAccess.Client.OracleConnection to create my oracle connection and Oracle 10g.
I'm calling this procedure from my app. By doing this am I causing it to only hold 4000 characters?
Here is a scaled down version of my code on just that column
CREATE OR REPLACE PROCEDURE EMAILINS (
P_MSG IN CLOB
AS
varT VARCHAR2(10000);
varSQL VARCHAR2(20000);
varTemp NUMBER;
BEGIN
-- SEE IF STRING EXISTS
SELECT 1 INTO varTemp
FROM tblEmail
WHERE TO_CHAR(MESSAGE) = P_MSG
EXCEPTION
WHEN TOO_MANY_ROWS THEN
varSQL := varT||CHR(10)||'***Multiple Rows Exist in Table tblEmail***';
DBMS_OUTPUT.PUT_LINE(varSQL);
WHEN NO_DATA_FOUND THEN
varT := P_MSG;
varSQL := 'INSERT INTO TBL_EMAIL( MESSAGE)'||CHR(10);
varSQL := varSQL || 'VALUES (tblEmail_SEQ.NEXTVAL,'||varT||')';
EXECUTE IMMEDIATE varSQL;
END EMAILINS;In the first place, you don't need (and surely don't want) dynamic SQL to do the insert. Replace
varT := P_MSG;
varSQL := 'INSERT INTO TBL_EMAIL( MESSAGE)'||CHR(10);
varSQL := varSQL || 'VALUES (tblEmail_SEQ.NEXTVAL,'||varT||')';
EXECUTE IMMEDIATE varSQL;with the simpler
INSERT INTO tbl_email( <<primary key column>>, message )
VALUES( tblEmail_Seq.nextval, p_msg );Secondly, you want to use the DBMS_LOB.COMPARE function to determine whether the contents of the LOBs match. So replace
SELECT 1
INTO varTemp
FROM tblEmail
WHERE TO_CHAR(MESSAGE) = P_MSG with
SELECT 1
INTO varTemp
FROM tblEmail
WHERE dbms_lob.compare( message, p_msg ) = 0Of course, it is going to be relatively expensive to run this query every time you insert a new message unless the table is always going to be very small, which seems unlikely. It also doesn't prevent duplicate entries if there are multiple threads executing at the same time.
Justin -
AQ/MGW clob issue - strange message
Oracle version 9.2.0.4
Solaris 8
I am using AQ with the Message Gateway to write to MQ , I am getting the following error/warning (?) in the mgw.log file
2004-09-06 04:07:15 MGW AQD:MsgConsumer 3 TRACE worker0 non-temporary CLOB: size=1420 for class:
oracle.mgw.drivers.aq.AQMsgConsumer$MgwBasicMsg_Dequeuer@26f75b
The message writes to MQ, and I can receive confirmations back into AQ. However
nothing is removed from AQ when dequeued ... this is machine specific as it runs
just fine on a different machine. Does anybody have any idea what this message means ?
I have looked high and low but cannot find an explanation/documentationThe way I have this transformation setup, I'm assuming it's
being run during the dequeue. Would this cause the message to be moved
to the AQ exception queue on the 9i instance? Am I creating the
transformation as the correct user (the one adding the subscription and scheduling the propagation th MQ)?
Dennis.............. -
Hi ,
I have a database in
Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bi
I have table tableAAA in database1,which has a clob column.
I want to select the CLOB column to Another database (database2)
So I create a view
(create or replace view my_view_tableAAA as select * from tableAAA)
view created
select * from schema.my_view_tableAAA@mydblink
(ORA-22992: cannot use LOB locators selected from remote tables)
What mistake am i doing ?
Rgds
SDBLink problem ORA-22992
Try the above, Google is really useful sometimes. -
EBS - 12 XMLP (5.6.3) cannot use CLOBS ?????
Hello: I am being told by Metalink Support the following:
" Bi Publisher 5.6.3 (10.1.3.2.0) does not have native support for CLOB.
This comes in BI Publisher Enterprise 10.1.3.3.0.
There are no plans at this time to upgrade EBS to higher versions of BI Publishe
r code."
So for EBS - 12, I cannot use CLOBS ?????
How am I supposed to write reports that use large CLOBS ?
Also, there was some mention about leaving out DataStructures in templates for CLOBS ?
Anyone with experience in this situation, please help ...
YeshHi Yesh,
There is a BI (XML) Publisher Desktop for 5.6.3 that you can use, and you can use the latest versions of the desktop to build your layouts, but be aware the later versions may have more supported features not present in 5.6.3. I use 10.1.3.something for developing EBS reports and have standalone BIP Server on my desktop for checking features against.
Data Templates are not the only way to register BIP reports in the EBS Concurrent Manager.
You can use **any** program as long as it does actually output XML and you have set the "Output" to XML.
The choice is up to you as to how you extract your data to XML - whatever works!
I'm not sure what all your CLOB issues are, but creating the XML that have CLOBS shouldn't cause issues (unless you are forced by something to use dataTemplates).
Gareth -
Passing CLOBs to SP now breaking
I'm working on an existing .NET 1.1 application using the ODP data provider to access a oracle 9 db. The application has been live and stable for quite some time. There are several SPs defined that accept clobs as parameter for Where/In filter fields and return non-clob/lob data. Recently these SP started failing with an ORA - 22922 missing LOB error. From some testing we have believe that this is an environment issue. However we cannot pin down what is causing it.
I have found a work around, however this is an extensive change to how we are accessing these SPs. Before recommending that we implement it I would like to try and track down what caused this. If any one has any idea it would be much appreciated.
The code that was used to pass the clob previously was:
oraCmd.Parameters.Add(New OracleParameter("COMP_FILTER", OracleDbType.Clob)).Value = COMP_FILTER
The work around requires the creating of a temp lob on the DB though a separate command, then passing that ID in to the SP. Not a small change.The COMP_FILTER value is just a ~ delimited string.
Nothing has changed on the oracle box that I know of. However the issue wasn't detected until I was asked to change a SP with the filter value. So it may have been outstanding for some time.
The failing code is as follows:
Dim oConn As New OracleConnection
Dim oraCmd As New OracleCommand("SAVECLOBDATA")
oConn.ConnectionString = _cmd.ConnectionString
oraCmd.CommandType = System.Data.CommandType.StoredProcedure
oraCmd.Parameters.Add(New OracleParameter("TNAME", OracleDbType.NVarchar2, 2000)).Value = TNAME
oraCmd.Parameters.Add(New OracleParameter("COMP_FILTER", OracleDbType.Clob)).Value = COMP_FILTER
oraCmd.Parameters.Add(New OracleParameter("CLOBFILEDNAME", OracleDbType.NVarchar2, 2000)).Value = CLOBFILEDNAME
oraCmd.Parameters.Add(New OracleParameter("KEYID", OracleDbType.NVarchar2, 2000)).Value = KEYID
oraCmd.Parameters.Add(New OracleParameter("KEYFIELD", OracleDbType.NVarchar2, 2000)).Value = KEYFIELD
Try
oConn.Open()
oraCmd.Connection = oConn
oraCmd.ExecuteNonQuery()
Catch ex As Exception
MsgBox(ex.Message)
Finally
oraCmd.Dispose()
oConn.Close()
End Try
End If
The now working code is as follows:
Dim oConn As New OracleConnection
Dim oraCmd As New OracleCommand("SAVECLOBDATA")
oConn.ConnectionString = _cmd.ConnectionString
oraCmd.CommandType = System.Data.CommandType.StoredProcedure
oraCmd.Parameters.Add(New OracleParameter("TNAME", OracleDbType.NVarchar2, 2000)).Value = TNAME
Dim trans As OracleTransaction
Try
oConn.Open()
trans = oConn.BeginTransaction
'MAV - 5/16/2k7 - Fix for ora-22922 clob issue, added transaction, moved parameters, added try block and changed creation of the CLOB
oraCmd.Parameters.Add(New OracleParameter("CLOBVALUE", OracleDbType.Clob)).Value = Me.CreateOraCLOBValue(oConn, trans, CLOBVALUE)
oraCmd.Parameters.Add(New OracleParameter("CLOBFILEDNAME", OracleDbType.NVarchar2, 2000)).Value = CLOBFILEDNAME
oraCmd.Parameters.Add(New OracleParameter("KEYID", OracleDbType.NVarchar2, 2000)).Value = KEYID
oraCmd.Parameters.Add(New OracleParameter("KEYFIELD", OracleDbType.NVarchar2, 2000)).Value = KEYFIELD
oraCmd.Connection = oConn
oraCmd.ExecuteNonQuery()
trans.Commit()
Catch ex As Exception
trans.Rollback()
MsgBox(ex.Message)
Finally
trans.Dispose()
oraCmd.Dispose()
oConn.Close()
End Try
End If
Protected Function CreateOraCLOBValue(ByRef oConn As OracleConnection, ByRef trans As OracleTransaction, ByVal data As String) As Oracle.DataAccess.Types.OracleClob
CreateOraCLOBValue = Nothing
Dim cmdLob As OracleCommand
cmdLob = oConn.CreateCommand
cmdLob.CommandText = "declare tmpClob clob; begin dbms_lob.createtemporary(tmpClob, false, 0); :tempblob := tmpClob; end;"
cmdLob.Parameters.Add(New OracleParameter("tempblob", OracleDbType.Clob)).Direction = ParameterDirection.Output
cmdLob.ExecuteNonQuery()
Dim lob As Oracle.DataAccess.Types.OracleClob
lob = cmdLob.Parameters(0).Value
lob.Write(data.ToCharArray(), 0, data.ToCharArray().GetLength(0))
CreateOraCLOBValue = lob
End Function -
I get this exception (and long stack trace) when attempting to start my weblogic server. I'm running Weblogic 7 with Portal 7 (sp 1). I'm using Oracle 8.1.7. I upgraded this application from weblogic portal 4.0, and never had this problem there. As part of the migration process, I ran the tool to migrate all of the database tables, and I re-synched the EBCC project using version 7 of EBCC. I did a search for this problem and found a few mentions of it that seemed to be related to Oracle's handling of CLOB data. Apparently, there is a patch, but I can't seem to find this patch. I'm also not sure if this is indeed the problem since I didn't have this issue with the older version of weblogic using the same database. Any suggestions?
If you have a support contract please open a case so we can work through
this problem.
Can you run an sqlplus session on your database, execute the commands
"delete from data_sync_item" and "commit", then resync to see if it will
get you around the problem. The data_sync_item table will be fully
populated after you sync. This should get you running.
Between 4.0 and 7.0 the DefaultRequestPropertySet.req file was reduced
in size -- the CLOB would be smaller in the data_sync_item table.
I would recommend using the Version Checker against your installation --
find it on the dev2dev.bea.com site to see if the upgrade installer work
ed properly. Also consider running the full installer to avoid possible
problems that might occur with upgrade installers.
As a result of that patch you referenced in 4.0 the CLOB handling logic
was changed in 7.0 -- this is why it is strange you are seeing cleaving
errors. In 7.0 SP2 to be release next week the data sync and
persistence code was changed also.
Are you using the OCI or Thin driver?
-- Jim
Rob Goldie wrote:
Jim Litton <replyto@newsgroup> wrote:
Rob,
The CLOB issue was related to wlportal4.0 and should not be a factor
in
7.0.
Could you post the entire stack trace?
####<Jan 27, 2003 4:21:47 PM EST> <Warning> <Data Synchronization> <PFIDEV5> <pfeAricept1Server>
<main> <kernel identity> <> <000000> <Application: gmiAriceptApp; Failed to retrieve
a schema URI (document namespace) for /request/DefaultRequestPropertySet.req;
please see the following exception for details.>
Exception[com.bea.p13n.management.data.doc.DocumentProcessingException: Unable
to analyze and/or cleave document]
at com.bea.p13n.management.data.doc.cleaver.CleavingDocumentProcessor.process(CleavingDocumentProcessor.java:94)
at com.bea.p13n.management.data.repository.internal.DataItemImpl.getSchemaUri(DataItemImpl.java:136)
at com.bea.p13n.management.data.repository.DataRepositoryFactory.createDataItem(DataRepositoryFactory.java:363)
at com.bea.p13n.management.data.repository.persistence.JdbcDataSource.createDataItems(JdbcDataSource.java:523)
at com.bea.p13n.management.data.repository.persistence.JdbcDataSource.refresh(JdbcDataSource.java:442)
at com.bea.p13n.management.data.repository.persistence.ReadOnlyJdbcPersistenceManager.refresh(ReadOnlyJdbcPersistenceManager.java:107)
at com.bea.p13n.management.data.repository.internal.AbstractDataRepository.<init>(AbstractDataRepository.java:193)
at com.bea.p13n.management.data.repository.internal.MasterDataRepository.<init>(MasterDataRepository.java:46)
at com.bea.p13n.management.data.repository.DataRepositoryFactory.getMasterDataRepository(DataRepositoryFactory.java:255)
at com.bea.p13n.placeholder.internal.PlaceholderServiceImpl.ejbCreate(PlaceholderServiceImpl.java:191)
at com.bea.p13n.placeholder.internal.PlaceholderServiceImpl_9p0jz2_Impl.ejbCreate(PlaceholderServiceImpl_9p0jz2_Impl.java:117)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.ejb20.pool.StatelessSessionPool.createBean(StatelessSessionPool.java:151)
at weblogic.ejb20.pool.Pool.createInitialBeans(Pool.java:188)
at weblogic.ejb20.manager.StatelessManager.initializePool(StatelessManager.java:380)
at weblogic.ejb20.deployer.EJBDeployer.initializePools(EJBDeployer.java:1472)
at weblogic.ejb20.deployer.EJBDeployer.start(EJBDeployer.java:1367)
at weblogic.ejb20.deployer.Deployer.deploy(Deployer.java:864)
at weblogic.j2ee.EJBComponent.deploy(EJBComponent.java:81)
at weblogic.j2ee.Application.addComponent(Application.java:294)
at weblogic.j2ee.J2EEService.addDeployment(J2EEService.java:164)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployment(DeploymentTarget.java:375)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployments(DeploymentTarget.java:303)
at weblogic.management.mbeans.custom.DeploymentTarget.updateServerDeployments(DeploymentTarget.java:256)
at weblogic.management.mbeans.custom.DeploymentTarget.updateDeployments(DeploymentTarget.java:207)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMBeanImpl.java:732)
at weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl.java:714)
at weblogic.management.internal.ConfigurationMBeanImpl.invoke(ConfigurationMBeanImpl.java:417)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1557)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1525)
at weblogic.management.internal.RemoteMBeanServerImpl.invoke(RemoteMBeanServerImpl.java:926)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:470)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:198)
at $Proxy9.updateDeployments(Unknown Source)
at weblogic.management.configuration.ServerMBean_CachingStub.updateDeployments(ServerMBean_CachingStub.java:4060)
at weblogic.management.deploy.slave.SlaveDeployer.updateServerDeployments(SlaveDeployer.java:2259)
at weblogic.management.deploy.slave.SlaveDeployer.resume(SlaveDeployer.java:373)
at weblogic.management.deploy.DeploymentManagerServerLifeCycleImpl.resume(DeploymentManagerServerLifeCycleImpl.java:235)
at weblogic.t3.srvr.ServerLifeCycleList.resume(ServerLifeCycleList.java:61)
at weblogic.t3.srvr.T3Srvr.resume(T3Srvr.java:806)
at weblogic.t3.srvr.T3Srvr.run(T3Srvr.java:295)
at weblogic.Server.main(Server.java:32)
Caused by: org.xml.sax.SAXException: No message available. Resource not found:
repository.cleaver.no.xsi.namespace.exception Resource bundle: com/bea/p13n/management/data/datasync
at com.bea.p13n.management.data.doc.cleaver.DocumentCleaver.mapNamespaces(DocumentCleaver.java:135)
at com.bea.p13n.management.data.doc.cleaver.DocumentCleaver.startElement(DocumentCleaver.java:235)
at weblogic.apache.xerces.parsers.SAXParser.startElement(SAXParser.java:1384)
at weblogic.apache.xerces.validators.common.XMLValidator.callStartElement(XMLValidator.java:1299)
at weblogic.apache.xerces.framework.XMLDocumentScanner.scanElement(XMLDocumentScanner.java:1821)
at weblogic.apache.xerces.framework.XMLDocumentScanner$ContentDispatcher.dispatch(XMLDocumentScanner.java:964)
at weblogic.apache.xerces.framework.XMLDocumentScanner.parseSome(XMLDocumentScanner.java:396)
at weblogic.apache.xerces.framework.XMLParser.parse(XMLParser.java:1119)
at weblogic.xml.jaxp.WebLogicXMLReader.parse(WebLogicXMLReader.java:135)
at weblogic.xml.jaxp.RegistryXMLReader.parse(RegistryXMLReader.java:133)
at com.bea.p13n.management.data.doc.cleaver.CleavingDocumentProcessor.process(CleavingDocumentProcessor.java:80)
at com.bea.p13n.management.data.repository.internal.DataItemImpl.getSchemaUri(DataItemImpl.java:136)
at com.bea.p13n.management.data.repository.DataRepositoryFactory.createDataItem(DataRepositoryFactory.java:363)
at com.bea.p13n.management.data.repository.persistence.JdbcDataSource.createDataItems(JdbcDataSource.java:523)
at com.bea.p13n.management.data.repository.persistence.JdbcDataSource.refresh(JdbcDataSource.java:442)
at com.bea.p13n.management.data.repository.persistence.ReadOnlyJdbcPersistenceManager.refresh(ReadOnlyJdbcPersistenceManager.java:107)
at com.bea.p13n.management.data.repository.internal.AbstractDataRepository.<init>(AbstractDataRepository.java:193)
at com.bea.p13n.management.data.repository.internal.MasterDataRepository.<init>(MasterDataRepository.java:46)
at com.bea.p13n.management.data.repository.DataRepositoryFactory.getMasterDataRepository(DataRepositoryFactory.java:255)
at com.bea.p13n.placeholder.internal.PlaceholderServiceImpl.ejbCreate(PlaceholderServiceImpl.java:191)
at com.bea.p13n.placeholder.internal.PlaceholderServiceImpl_9p0jz2_Impl.ejbCreate(PlaceholderServiceImpl_9p0jz2_Impl.java:117)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.ejb20.pool.StatelessSessionPool.createBean(StatelessSessionPool.java:151)
at weblogic.ejb20.pool.Pool.createInitialBeans(Pool.java:188)
at weblogic.ejb20.manager.StatelessManager.initializePool(StatelessManager.java:380)
at weblogic.ejb20.deployer.EJBDeployer.initializePools(EJBDeployer.java:1472)
at weblogic.ejb20.deployer.EJBDeployer.start(EJBDeployer.java:1367)
at weblogic.ejb20.deployer.Deployer.deploy(Deployer.java:864)
at weblogic.j2ee.EJBComponent.deploy(EJBComponent.java:81)
at weblogic.j2ee.Application.addComponent(Application.java:294)
at weblogic.j2ee.J2EEService.addDeployment(J2EEService.java:164)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployment(DeploymentTarget.java:375)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployments(DeploymentTarget.java:303)
at weblogic.management.mbeans.custom.DeploymentTarget.updateServerDeployments(DeploymentTarget.java:256)
at weblogic.management.mbeans.custom.DeploymentTarget.updateDeployments(DeploymentTarget.java:207)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMBeanImpl.java:732)
at weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl.java:714)
at weblogic.management.internal.ConfigurationMBeanImpl.invoke(ConfigurationMBeanImpl.java:417)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1557)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1525)
at weblogic.management.internal.RemoteMBeanServerImpl.invoke(RemoteMBeanServerImpl.java:926)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:470)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:198)
at $Proxy9.updateDeployments(Unknown Source)
at weblogic.management.configuration.ServerMBean_CachingStub.updateDeployments(ServerMBean_CachingStub.java:4060)
at weblogic.management.deploy.slave.SlaveDeployer.updateServerDeployments(SlaveDeployer.java:2259)
at weblogic.management.deploy.slave.SlaveDeployer.resume(SlaveDeployer.java:373)
at weblogic.management.deploy.DeploymentManagerServerLifeCycleImpl.resume(DeploymentManagerServerLifeCycleImpl.java:235)
at weblogic.t3.srvr.ServerLifeCycleList.resume(ServerLifeCycleList.java:61)
at weblogic.t3.srvr.T3Srvr.resume(T3Srvr.java:806)
at weblogic.t3.srvr.T3Srvr.run(T3Srvr.java:295)
at weblogic.Server.main(Server.java:32)
Are you using a UTF-8 Oracle database?
Yes
If you create a new User Profile in the EBCC and compare it to your
migrated .usr file do you see differences in the DTD's?
I recreated a new version of the .usr in the EBCC, and still got the same error.
I also tried deleting everything from the data-sync-item table and re-synching.
What does the DocumentManager section of your application-config.xml
look like?
<DocumentManager
ContentCacheName="documentContentCache"
ContentCaching="true"
DocumentConnectionPoolName="default"
MaxCachedContentSize="32768"
MetadataCacheName="documentMetadataCache"
MetadataCaching="true"
Name="default"
PropertyCase="none"
UserIdInCacheKey="false"
/>
What does the document.jar Targets="" parameter look like in config.xml?
<EJBComponent Name="document" Targets="pfeCluster" URI="document.jar"/>
-- Jim
Rob Goldie wrote:
I get this exception (and long stack trace) when attempting to start
my weblogic server. I'm running Weblogic 7 with Portal 7 (sp 1). I'm
using Oracle 8.1.7. I upgraded this application from weblogic portal
4.0, and never had this problem there. As part of the migration process,
I ran the tool to migrate all of the database tables, and I re-synched
the EBCC project using version 7 of EBCC. I did a search for this problem
and found a few mentions of it that seemed to be related to Oracle's
handling
of CLOB data. Apparently, there is a patch, but I can't seem to find
this patch. I'm also not sure if this is indeed the problem since I
didn't have this issue with the older version of weblogic using the
same database. Any suggestions? -
Oracle / Redhat Linux / Portal Server | Sample Portal Error
Team:
I know I saw the listings for the patch_CR067935.zip which address what
seems to be a similar problem with the JDBC Helper Service, but I am not
sure this is the same issue.
I just installed Portal Service Pack1 and did all the procedures for the
move to Oracle Database. I even See the Oracle Pools COnnecting and in
the Admin Console.
===================
WHEN I TRY TO ACCESS THE SAMPLE PORTAL I GET THE FOLLOWING ERROR:
Is this the patch_CR067935.zip issue or do I have another Issue?
Thank you in advance................
####<Feb 22, 2002 4:16:52 PM EST> <Error> <HTTP> <localhost.localdomain>
<portalServer> <ExecuteThread: '11' for queue: 'default'> <> <> <101018>
<[WebAppServletContext(1573598,stockportal,/stockportal)] Servlet failed
with ServletException>
javax.servlet.ServletException: Received a null Portal object from the
PortalManager.
at
com.bea.portal.appflow.servlets.internal.PortalWebflowServlet.setupPortalRequest(PortalWebflowServlet.java:194)
at
com.bea.portal.appflow.servlets.internal.PortalWebflowServlet.doGet(PortalWebflowServlet.java:99)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:265)
at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:200)
at
weblogic.servlet.internal.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:215)
at weblogic.servlet.jsp.PageContextImpl.forward(PageContextImpl.java:112)
at jsp_servlet.__index._jspService(__index.java:92)
at weblogic.servlet.jsp.JspBase.service(JspBase.java:27)
at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:265)
at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:304)
at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:200)
at
weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletContext.java:2459)
at
weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java:2039)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:139)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)Hi Mr. BigMAN,
I'm not sure if the CLOB issue solved by patch_CR067935.zip has this symptom. In any case, you should install
the patch because you will need it if you are going to use Portal 4.0 sp1 with Oracle. Everyone out there who is
using Oracle with Portal 4.0 sp1 should install this patch (search for "67935" at this location:
http://e-docs.bea.com/wlp/docs40/relnotes/relnotes.htm#246667
Back to your current problem: Did you run the loadSampleData script? Try running it after you install the
patch. ( http://edocs.bea.com/wlp/docs40/deploygd/oraclnew.htm#1040434 ). Also, make sure you set up the JDBC
Helper Service for all of the J2EE applications that use JDBC services. (
http://edocs.bea.com/wlp/docs40/deploygd/oraclnew.htm#1064575 ). You need to configure the p13nApp, portal, and
wlcsApp.
Let me know if you continue to have problems with this and I'll see what I can do to help.
"Mr. BigMAN" wrote:
Team:
I know I saw the listings for the patch_CR067935.zip which address what
seems to be a similar problem with the JDBC Helper Service, but I am not
sure this is the same issue.
I just installed Portal Service Pack1 and did all the procedures for the
move to Oracle Database. I even See the Oracle Pools COnnecting and in
the Admin Console.
===================
WHEN I TRY TO ACCESS THE SAMPLE PORTAL I GET THE FOLLOWING ERROR:
Is this the patch_CR067935.zip issue or do I have another Issue?
Thank you in advance................
####<Feb 22, 2002 4:16:52 PM EST> <Error> <HTTP> <localhost.localdomain>
<portalServer> <ExecuteThread: '11' for queue: 'default'> <> <> <101018>
<[WebAppServletContext(1573598,stockportal,/stockportal)] Servlet failed
with ServletException>
javax.servlet.ServletException: Received a null Portal object from the
PortalManager.
at
com.bea.portal.appflow.servlets.internal.PortalWebflowServlet.setupPortalRequest(PortalWebflowServlet.java:194)
at
com.bea.portal.appflow.servlets.internal.PortalWebflowServlet.doGet(PortalWebflowServlet.java:99)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:265)
at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:200)
at
weblogic.servlet.internal.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:215)
at weblogic.servlet.jsp.PageContextImpl.forward(PageContextImpl.java:112)
at jsp_servlet.__index._jspService(__index.java:92)
at weblogic.servlet.jsp.JspBase.service(JspBase.java:27)
at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:265)
at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:304)
at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:200)
at
weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletContext.java:2459)
at
weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java:2039)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:139)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)--
Ture Hoefner
BEA Systems, Inc.
2590 Pearl St.
Suite 110
Boulder, CO 80302
www.bea.com -
CLOB / Charset / Java / Unix Issue
Hi,
I'm encountering the following problem.
I'm working on a 3-tiers architecture with an Oracle Database (8.1.7)
a Weblogic application server 6.1 SP4 and a Web server under Aix 4.3
(all 3 are under AIX 4.3 on the same platform).
My application has a web interface that allows users to upload files
to the server from their PC clients and a webbrowser, that insert each
file into a oracle Clob (via Java Code) and that call a stored
procedure (with java code again) to extract this clob to a file
(UTL_file package), then, the extracted file is processed line by line
and information inserted in others tables.
The issue is that some characters (acute, grave accent ....etc)
appears as question marks in the database or that some date from the
file can't be processed because they are structured as DD/MM/YYYY
(french notation, but that normal I'm from france).
I first thougt of an NLS_LANG problem but on the weblogic server it is
set to french_france.WE88859P15 that seems to be right and the same
the database configuration.
I then tried to performs some conversion when the clob data were
extracted to file (from WE88859P15 TO CP152 or vice-versa) with the
oracle convert function but it seems that it doesn't work.
An other but coherent symptoms is that the extracted files (from the
clob columns) seems not to be fine (accent are not recognized).
This is the java code used to load file to clob (on the weblogic
server side)
con = dbHandle.getAdminConnection();
con.setAutoCommit(false);
/// NEW IMPORT
// int taskId = DBTools.getOraSeqValue("vtr.VTR_SEQ_LOG_IMPORT",
DBTools.NEXTVAL,con);
int taskId = DBTools.getOraSeqValue(SqlQueryDefinition.seqLogImport.toString(),
DBTools.NEXTVAL,con);
Debug.out.println("taskId " + taskId);
// String cmd = "insert into vtr.vtr_log_import
(cod_task,DTE_DEBUT,lob_imp,lob_rej,lob_log, txt_nom_fic_orig,
txt_utilisateur) " +
// "values ("+ taskId
+",sysdate,empty_clob(),empty_clob(),empty_clob(), '"+file+"','"+
((UserBean)request.getSession().getAttribute("userbean")).getIdentifier()+"')";
// stmt = con.createStatement();
// stmt.executeQuery(cmd);
// stmt.close();
pstmt = con.prepareStatement(SqlQueryDefinition.initLigneImport.toString());
pstmt.setInt(1,taskId);
pstmt.setString(2,file);
pstmt.setString(3,((UserBean)request.getSession().getAttribute("userbean")).getIdentifier());
pstmt.executeQuery();
pstmt.close();
con.commit();
// Writing CLOB
// cmd = "SELECT cod_task,lob_imp,lob_rej,lob_log FROM
vtr.vtr_log_import WHERE cod_task="+ taskId +" for update";
// stmt = con.createStatement();
// rset = stmt.executeQuery(cmd);
pstmt = con.prepareStatement(SqlQueryDefinition.setBlobImport.toString());
pstmt.setInt(1,taskId);
rset = pstmt.executeQuery();
rset.next();
File csvFile = new File(localFile);
System.out.println("csvFile length = " + csvFile.length());
File unixFile = new File(localFile+".ux");
Tools.dos2Unix(csvFile, unixFile);
FileInputStream instream = new FileInputStream(unixFile);
// support Weblogic
clob = ClobComponent.factory(DBUtil.getInstance().isWebLogicPlatform());
clob.setClob(rset,2);
outstream = clob.getAsciiOutputStream();
size = clob.getBufferSize();
byte[] buffer = new byte[size];
int length = -1;
while ((length = instream.read(buffer)) != -1)
outstream.write(buffer, 0, length);
instream.close();
outstream.close();
rset.close();
// stmt.close();
pstmt.close();
rset=null;
// stmt = null;
pstmt=null;
con.commit();
// IMPORT
cs = con.prepareCall(SqlQueryDefinition.importStoredProc.toString());
index = 1;
cs.setString(index++, fullPath); // 1
cs.setString(index++,
((UserBean)request.getSession().getAttribute("userbean")).getIdentifier());
// 2
cs.registerOutParameter(index++,java.sql.Types.VARCHAR); // 3
cs.registerOutParameter(index++,java.sql.Types.VARCHAR); // 4
cs.registerOutParameter(index++,java.sql.Types.NUMERIC); // 5
cs.setInt(index++, taskId); // 6
cs.executeQuery();
String fichier1 = cs.getString(3);
String fichier2 = cs.getString(4);
int returnCode = cs.getInt(5);
System.out.println("returnCode/fichier1/2 : " + returnCode + " & "
+ fichier1 + " & " + fichier2);
cs.close();
con.commit();
This is the PL/SQL code used to unload clob to dile (on the oracle
side)
PROCEDURE writeToFile (id NUMBER, a_fichier VARCHAR2)
IS
result CLOB;
cvl_tmp VARCHAR2 (32000);
nvl_amount NUMBER := 250;
nvl_pos NUMBER := 1;
nvl_clob_length NUMBER;
instr_pos NUMBER;
file_handle UTL_FILE.file_type;
BEGIN
file_handle := UTL_FILE.FOPEN(
substr(a_fichier, 1, instr(a_fichier, file_separator, -1,
1)-1), -- dir
substr(a_fichier, instr(a_fichier, file_separator, -1, 1)+1),
-- file
'W');
select lob_imp
INTO result
from vtr_log_import
where cod_task = id;
--write clob to file
nvl_clob_length := DBMS_LOB.getlength (result);
cvl_tmp := NULL;
nvl_amount := 250;
nvl_pos := 1;
LOOP
instr_pos :=
DBMS_LOB.INSTR (result, CHR (10), nvl_pos, 1) -
nvl_pos;
--DBMS_OUTPUT.PUT_LINE(nvl_pos||': Of length : '||instr_pos);
IF nvl_pos + instr_pos > nvl_clob_length
THEN
instr_pos := nvl_clob_length - nvl_pos;
DBMS_LOB.READ (
lob_loc=> result,
amount=> instr_pos,
offset=> nvl_pos,
buffer=> cvl_tmp
EXIT;
END IF;
DBMS_LOB.READ (
lob_loc=> result,
amount=> instr_pos,
offset=> nvl_pos,
buffer=> cvl_tmp
-- DBMS_OUTPUT.PUT_LINE(cvL_tmp);
cvl_tmp := CONVERT(cvl_tmp, 'WE8MSWIN1252', 'WE8ISO8859P15');
UTL_FILE.put_line (file_handle, cvl_tmp);
nvl_pos := nvl_pos
+ instr_pos
+ 1;
IF nvl_pos > nvl_clob_length
THEN
EXIT;
END IF;
END LOOP;
UTL_FILE.fclose (file_handle);
END writeToFile;
I'm using the oracle thin driver but it's not set in classpath maybe a
problem with that ?
<JDBCConnectionPool DriverName="oracle.jdbc.driver.OracleDriver"
InitialCapacity="1" MaxCapacity="100" Name="oracleUserPool"
Password="XXXXXXX
Properties="user=vtr_usr;dll=ocijdbc8;protocol=thin"
Targets="myserver" TestConnectionsOnRelease="true"
TestConnectionsOnReserve="true" TestTableName="dual"
URL="jdbc:oracle:thin:@localhost:1521:ssr"/>
Maybe a problem with the properties of weblogic.codeset (I don"t set
it) ?
Many thanks in advance, I have no idea even if I suspect the java
store to file or the UTL_file extration to file steps to be in cause !
Run-ORun-O wrote:
Hi,
I'm encountering the following problem.Hi. The first thing I'd do to narrow the search is to see if my Java code
worked in a standalone program, without weblogic in the picture. Once
you get Oracle's JDBC driver to work with Oracle's DBMS, it shouldn't
be hard to get the same stuff to work inside weblogic, or find out why it
doesn't.
Joe
>
>
I'm working on a 3-tiers architecture with an Oracle Database (8.1.7)
a Weblogic application server 6.1 SP4 and a Web server under Aix 4.3
(all 3 are under AIX 4.3 on the same platform).
My application has a web interface that allows users to upload files
to the server from their PC clients and a webbrowser, that insert each
file into a oracle Clob (via Java Code) and that call a stored
procedure (with java code again) to extract this clob to a file
(UTL_file package), then, the extracted file is processed line by line
and information inserted in others tables.
The issue is that some characters (acute, grave accent ....etc)
appears as question marks in the database or that some date from the
file can't be processed because they are structured as DD/MM/YYYY
(french notation, but that normal I'm from france).
I first thougt of an NLS_LANG problem but on the weblogic server it is
set to french_france.WE88859P15 that seems to be right and the same
the database configuration.
I then tried to performs some conversion when the clob data were
extracted to file (from WE88859P15 TO CP152 or vice-versa) with the
oracle convert function but it seems that it doesn't work.
An other but coherent symptoms is that the extracted files (from the
clob columns) seems not to be fine (accent are not recognized).
This is the java code used to load file to clob (on the weblogic
server side)
con = dbHandle.getAdminConnection();
con.setAutoCommit(false);
/// NEW IMPORT
// int taskId = DBTools.getOraSeqValue("vtr.VTR_SEQ_LOG_IMPORT",
DBTools.NEXTVAL,con);
int taskId = DBTools.getOraSeqValue(SqlQueryDefinition.seqLogImport.toString(),
DBTools.NEXTVAL,con);
Debug.out.println("taskId " + taskId);
// String cmd = "insert into vtr.vtr_log_import
(cod_task,DTE_DEBUT,lob_imp,lob_rej,lob_log, txt_nom_fic_orig,
txt_utilisateur) " +
// "values ("+ taskId
+",sysdate,empty_clob(),empty_clob(),empty_clob(), '"+file+"','"+
((UserBean)request.getSession().getAttribute("userbean")).getIdentifier()+"')";
// stmt = con.createStatement();
// stmt.executeQuery(cmd);
// stmt.close();
pstmt = con.prepareStatement(SqlQueryDefinition.initLigneImport.toString());
pstmt.setInt(1,taskId);
pstmt.setString(2,file);
pstmt.setString(3,((UserBean)request.getSession().getAttribute("userbean")).getIdentifier());
pstmt.executeQuery();
pstmt.close();
con.commit();
// Writing CLOB
// cmd = "SELECT cod_task,lob_imp,lob_rej,lob_log FROM
vtr.vtr_log_import WHERE cod_task="+ taskId +" for update";
// stmt = con.createStatement();
// rset = stmt.executeQuery(cmd);
pstmt = con.prepareStatement(SqlQueryDefinition.setBlobImport.toString());
pstmt.setInt(1,taskId);
rset = pstmt.executeQuery();
rset.next();
File csvFile = new File(localFile);
System.out.println("csvFile length = " + csvFile.length());
File unixFile = new File(localFile+".ux");
Tools.dos2Unix(csvFile, unixFile);
FileInputStream instream = new FileInputStream(unixFile);
// support Weblogic
clob = ClobComponent.factory(DBUtil.getInstance().isWebLogicPlatform());
clob.setClob(rset,2);
outstream = clob.getAsciiOutputStream();
size = clob.getBufferSize();
byte[] buffer = new byte[size];
int length = -1;
while ((length = instream.read(buffer)) != -1)
outstream.write(buffer, 0, length);
instream.close();
outstream.close();
rset.close();
// stmt.close();
pstmt.close();
rset=null;
// stmt = null;
pstmt=null;
con.commit();
// IMPORT
cs = con.prepareCall(SqlQueryDefinition.importStoredProc.toString());
index = 1;
cs.setString(index++, fullPath); // 1
cs.setString(index++,
((UserBean)request.getSession().getAttribute("userbean")).getIdentifier());
// 2
cs.registerOutParameter(index++,java.sql.Types.VARCHAR); // 3
cs.registerOutParameter(index++,java.sql.Types.VARCHAR); // 4
cs.registerOutParameter(index++,java.sql.Types.NUMERIC); // 5
cs.setInt(index++, taskId); // 6
cs.executeQuery();
String fichier1 = cs.getString(3);
String fichier2 = cs.getString(4);
int returnCode = cs.getInt(5);
System.out.println("returnCode/fichier1/2 : " + returnCode + " & "
+ fichier1 + " & " + fichier2);
cs.close();
con.commit();
This is the PL/SQL code used to unload clob to dile (on the oracle
side)
PROCEDURE writeToFile (id NUMBER, a_fichier VARCHAR2)
IS
result CLOB;
cvl_tmp VARCHAR2 (32000);
nvl_amount NUMBER := 250;
nvl_pos NUMBER := 1;
nvl_clob_length NUMBER;
instr_pos NUMBER;
file_handle UTL_FILE.file_type;
BEGIN
file_handle := UTL_FILE.FOPEN(
substr(a_fichier, 1, instr(a_fichier, file_separator, -1,
1)-1), -- dir
substr(a_fichier, instr(a_fichier, file_separator, -1, 1)+1),
-- file
'W');
select lob_imp
INTO result
from vtr_log_import
where cod_task = id;
--write clob to file
nvl_clob_length := DBMS_LOB.getlength (result);
cvl_tmp := NULL;
nvl_amount := 250;
nvl_pos := 1;
LOOP
instr_pos :=
DBMS_LOB.INSTR (result, CHR (10), nvl_pos, 1) -
nvl_pos;
--DBMS_OUTPUT.PUT_LINE(nvl_pos||': Of length : '||instr_pos);
IF nvl_pos + instr_pos > nvl_clob_length
THEN
instr_pos := nvl_clob_length - nvl_pos;
DBMS_LOB.READ (
lob_loc=> result,
amount=> instr_pos,
offset=> nvl_pos,
buffer=> cvl_tmp
EXIT;
END IF;
DBMS_LOB.READ (
lob_loc=> result,
amount=> instr_pos,
offset=> nvl_pos,
buffer=> cvl_tmp
-- DBMS_OUTPUT.PUT_LINE(cvL_tmp);
cvl_tmp := CONVERT(cvl_tmp, 'WE8MSWIN1252', 'WE8ISO8859P15');
UTL_FILE.put_line (file_handle, cvl_tmp);
nvl_pos := nvl_pos
+ instr_pos
+ 1;
IF nvl_pos > nvl_clob_length
THEN
EXIT;
END IF;
END LOOP;
UTL_FILE.fclose (file_handle);
END writeToFile;
I'm using the oracle thin driver but it's not set in classpath maybe a
problem with that ?
<JDBCConnectionPool DriverName="oracle.jdbc.driver.OracleDriver"
InitialCapacity="1" MaxCapacity="100" Name="oracleUserPool"
Password="XXXXXXX
Properties="user=vtr_usr;dll=ocijdbc8;protocol=thin"
Targets="myserver" TestConnectionsOnRelease="true"
TestConnectionsOnReserve="true" TestTableName="dual"
URL="jdbc:oracle:thin:@localhost:1521:ssr"/>
Maybe a problem with the properties of weblogic.codeset (I don"t set
it) ?
Many thanks in advance, I have no idea even if I suspect the java
store to file or the UTL_file extration to file steps to be in cause !
Run-O -
Issue with usage of Clob variable to hold the output data...
Hi All,
we are getting the output of the sql query out from a function and this function return type is defined as CLOB.
because of the volume of data being fetched we are getting the below mentioned error message when this Function is getting executed.
“ORA-06502: PL/SQL: numeric or value error”. : character string buffer too small
Now even with CLOB if we are getting the buffer too small error message ...is there any other way or approach we could handle this..
our requirement is to fetch the complete value from this function in one shot and we don't want to split the data based on the size / number of characters...
This is causing us lot of issues...could someone please suggest as to what could be done regards this ...Post your script. How can we tell when we can't see your code.
Also, better to post the table ddl's script and some demo insert statement here. And, please provide the DB version, too.
Generally, you should not get such error. So, please post these details.
Regards.
Satyaki De. -
Issue while generating MD5 if there are any special characters in the CLOB
Hi Guys,
I need your help...
We are using dbms_crypto.hash to generate the MD5 hash value for a CLOB that will be sent to other feeder systems. The feeder systems validate the file by generating the MD5 hash value on their end and compare with the MD5 generated in Oracle and accept the file only if the MD5 hash value matches.
The MD5 file matches between both the systems except in the case where there are special characters in the CLOB. Somehow, MD5 is prefixing  character before any special character and calculating the MD5 value. In our case, our special characters being ®, §, ™, ©....
This is a high priority issue for us and it is holding our UAT.
We are using Oracle 11.2.0.2.0.
Your response is really appreciated.
Best Regards
GuptaWelcome to the forum!
Whenever you post provide your 4 digit Oracle version.
>
We are using dbms_crypto.hash to generate the MD5 hash value for a CLOB that will be sent to other feeder systems. The feeder systems validate the file by generating the MD5 hash value on their end and compare with the MD5 generated in Oracle and accept the file only if the MD5 hash value matches.
The MD5 file matches between both the systems except in the case where there are special characters in the CLOB. Somehow, MD5 is prefixing  character before any special character and calculating the MD5 value. In our case, our special characters being ®, §, ™, ©....
>
See if my reply in this thread addresses your problem.
Re: MD5 HASH computed from DBMS_CRYPTO does not match .NET MD5
The fix in almost all of these cases is to understand that the Crypto package always converts everything to AL32UTF8 before hashing.
ALWAYS.
ALWAYS.
ALWAYS.
Unless the 'other' hash generators (substitute any generator you wish) do it the Oracle way you will NEVER get a match.
NEVER.
NEVER.
NEVER.
There are no workarounds. -
Issues with CLOB dataype in 10g. (Data truncation)
I have a product which is running perfectly fine on Oralce 9i. We are trying to upgrade the product to 10g. Once the database is upgraded and after the data is imported, we are facing few issues with CLOB data type values. We are using SQLGetData function to fetch data from these CLOB datatypes. The data is getting truncated when retriving. Oracle says, its an issue with ODBC driver which was released with 10g Relase 1. I tried to upgrade the ODBC driver. But even after upgrading, I am still facing the same issue. I tried to upgrade it Oracle 10g Release 2. Still I am facing the same issue. The data stored in CLOB datatype is xml data. So after retriving the truncated data, XML parser is not able to parse the data.
When I trace the error using ODBC Error Tracing, I am getting this error :
[01004] [Oracle][ODBC]String data, right truncated. (0) .
Has anyone faced anything like this. your inputs will be greatly appreciated.
Thanks in advance.Hi,
Thanks for the reply. I couldn't quite got what you meant by referential variable. Could you please elaborate on that.
Thanks in advance. -
Oracle Issue around handling CLOB within Workflow Transaction
Hi,
- In Workflow Notification Message I am using an CLOB Document for building the
message Body
- This CLOB value is going to be SELECTed and initialized from a TABLE
(having CLOB column) during the document related procedure execution
NOTE: In order to select from a CLOB we need to issue FOR UPDATE
to have read consistency
(otherwise it will give LOB not locked for update error during notification display)
Here the issue I am facing is :
The same notification is going to be sent to Multiple users (thru Notification
to a Apps.Responsibility i.e. WF Role)
When USER1 opens the notification, the CLOB Table row gets a lock
(due to FOR UPDATE) and is not released until ROLLBACK/COMMIT
which will not happen as it is a workflow (if I put this Select FOR UPDATE
in a AUTONOMOUS transaction then it gives error as LOCATOR id cannot
spawn between transactions during the notification display)
When USER2/USER3 opens the same notification which he received being a member
of the Responsibility , the notificaiton screen gets hanged as it again
tries to issue SELECT FOR UPDATE and sees USER1 holds the lock.
My Requirement is:
When first time anyone user opens the notification, it will not find a record in table
so it builds the notification and stores the CLOB record into the table.
Next time onwards all the users should get the stored record from the table
(Read CLOB value from Table and show in the Notification Message Body)
Please help me in resolving the SELECT FOR UPDATE of a CLOB within Workflow
when multiple users need to issue without the need of a COMMIT/ROLLBACK
NOTE: Even I am only Reading the CLOB value from a Table, without
having any need of updating it, still I need to Issue FOR UPDATE
as per Oracle CLOB constraint.
thanks,
ShashiHi,
I didn't do the select directly into document when I did it in my test. Here's the two different methods that I used in my database to test the problem:
create or replace procedure msclobtest
(document_id IN VARCHAR2
,display_type IN VARCHAR2
,document OUT CLOB
,document_type OUT VARCHAR2
) as
cursor c1 is select theclob from ms3 where clob_id = 4;
v_clob clob;
begin
debug('started clob');
open c1;
fetch c1 into v_clob;
close c1;
document := v_clob;
document_type := 'text/html';
debug('clob ended');
end;
create or replace procedure msclobtest
(document_id IN VARCHAR2
,display_type IN VARCHAR2
,document OUT CLOB
,document_type OUT VARCHAR2
) as
cursor c1 is select theclob from ms3 where clob_id = 4;
v_clob clob;
begin
open c1;
fetch c1 into v_clob;
close c1;
dbms_lob.createtemporary(document,FALSE);
dbms_lob.copy(document,v_clob,dbms_lob.getlength(v_clob));
document_type := 'text/html';
end;If it's not the code, then it might be something in the Workflow itself.
Are the values of the document attribute being set correctly in the Workflow? Are you sending to a role? Have you checked the "Expand Roles" tick box? Have you checked the "Attach Content" tick box?
Matt
Alpha review chapters from my book "Developing With Oracle Workflow" are available on my website:
http://www.workflowfaq.com
http://forum.workflowfaq.com -
I am not sure if this is the correct forum for this question, so please forgive if this is posted in wrong forum.
I am new to working with CLOBs in Oracle. The procedure updates a CLOB column which stores large XML files. The XML files are first moved to the /u04 directory, then we execute the procedure which looks for the XML in /u04, then uses those XML files to update the CLOB column.
The procure works fine in our development environment, but doesn't work in our System Test box. No exceptions are thrown in Sys Test, but when we check the CLOB column it's NULL/empty.
Both Dev and Sys Test environments are on the same physical server.
Is there something in the database setup I should be looking for which may cause this difference in functionality?
Code is below. I'm sure it could be better but this is my first go-around with CLOBs.
Any help is greatly appreciated!
--open CLOB used to clear out old XML in CLOB column
dbms_lob.open(v_pre_clob, dbms_lob.lob_readwrite);
-- prep XML CLOB column for update
UPDATE REPORT_TBL
SET REPORT_XML = v_pre_clob
WHERE REPORT_ID = p_rep_id;
--Close pre-update CLOB
dbms_lob.close(v_pre_clob);
--get a reference to the XML CLOB that needs to be updated
select report_xml
into v_clob
from report_tbl
where report_id = p_rep_id for update;
--open the target CLOB and source report xml file in /u04
dbms_lob.open(v_clob, dbms_lob.lob_readwrite);
dbms_lob.open(v_report_xml_file);
--Load the contents of the xml file in /u04 into the CLOB column
dbms_lob.loadclobfromfile(v_clob, v_xml_file,
dbms_lob.lobmaxsize,
v_destination_offset, v_source_offset,
nls_charset_id('US7ASCII'),
v_language_context, v_warning_message);
--Check for the only possible warning message.
if v_warning_message = dbms_lob.warn_inconvertible_char then
dbms_output.put_line('Warning! Some characters couldn''t be converted.');
end if;
--Close both LOBs
dbms_lob.close(v_clob);
dbms_lob.close(v_xml_file);
null;
EXCEPTION
WHEN OTHERS THEN
v_return_code := SQLCODE;
v_return_mesg := SQLERRM;
DBMS_OUTPUT.PUT_LINE('PROCEDURE update_xml_from_file');
DBMS_OUTPUT.PUT_LINE('RETURN_CODE = ' || v_return_code);
DBMS_OUTPUT.PUT_LINE('RETURN_MESG = ' || v_return_mesg);Sorry, pulled that code from development where it was working.
The issue was the GRANT on the /u04 directory.
Maybe you are looking for
-
Error saving data structure CE11000 (please read log) message number KX 655
while activating the data structure in the operating concern of CO PA sap gives the following errors. 1.Error saving data structure CE11000 (please read log) Message no. KX655 2.Error saving table CE01000 Message no. KX593 3.in Log Reference field CE
-
Mac Pro with Aperture - very slow
Why, why couldn't it be faster? I've been reading about the Mac Pros since they were announced last week. The local Apple store finally got one and I went to go see it. And there it was -- 42 lb glory, standard configuration, driving a 30" screen. I
-
Can you connect 2 separate apple tv in same house?
can you conndct 2 separate apple tv in same house? ( only one apple computor)
-
Macbook typing rubbish instead of text
My wifes Macbook (new Jan2010) does not type text but a series of symbols instead. This happens on every key and regardless of whether she has it on English, Russian or Azeri language inputs. I have tried to change the language and text options but t
-
Delegate Calendar Entries disappear seconds after creation
Environment. Exchange 2010 on prem. Office 2013. CEO and COO have the same Executive Assistant. This person has Manage Full Access Permissions for both CEO and COO. She regularly adds calendar events to either persons calendar without issue for the p