Event Driven Publishing API 11 GR 2 - ORA-06512: at line 20

Hello

I use event driven api publishing to send the report to our users, I use the procedure to do this, but the procedure executes with the error

declare

*

ERROR on line 1:

ORA-20999:

ORA-06512: at «NRSP.» SRW", line 264

ORA-06512: at «NRSP.» SRW", line 799

ORA-06512: at line 20

no additional information about the cause of the error.

Please help about this.

Database: 11 GR 2

Train services: 11 GR 2

RAC (2 knots)

-procedure

declare

myPlist SRW_PARAMLIST;

myIdent SRW. Job_Ident;

myStatus SRW. Status_Record;

BEGIN

SRW.start_debugging;

myPlist: = SRW_PARAMLIST (SRW_PARAMETER('',''));

srw.add_parameter (myPlist, 'GATEWAY','http://192.168.5.35:8888/reports/rwservlet ');

SRW. ADD_PARAMETER (myPlist, "SERVER", "rep_wls_reports_conho_asnist_1");

SRW.add_parameter(myPlist,'REPORT','D:\Reports\EMP_ABSNTE_AUTO.rdf');

SRW.add_parameter(myPlist,'USERID','usr/pwd@mydb');

SRW.add_parameter (myPlist, 'DESTYPE', 'email');

SRW.add_parameter (myPlist, 'DESFORMAT', 'PDF');

srw.add_parameter (myPlist, 'DESNAME',' [email protected]');

SRW.add_parameter (myPlist, 'SUBJECT', 'Monthly absent notice');

srw.add_parameter (myPlist, "FROM",' [email protected]');

myIdent: = srw.run_report (myPlist);

myStatus: = srw.report_status (myIdent);

SRW.stop_debugging;

end;

/


The debug output should tell you more. See this thread:

Report in PDF format and send it to some clients, using database triggers

Tags: Oracle Development

Similar Questions

  • Error when inserting a record - a feature not taken in charge with clause RETURNING ORA-06512: at line 1

    Hello

    I have a created an EO based on a synonym (synonym is created for a Table by using binding remote Db)

    I created a from VO of the EO above and added to an AM. When I run the AM and try to insert a record I get following error

    [164] BEGIN INSERT INTO TRACK_TRANSACTION_STATUS_BIZ (TRANS_NO, TRANS_ID, START_DATE, LOGIN_USER_ID, SESSION_ID, REFUND_APPLICABLE_IND) VALUES (: 1,: 2,: 3,: 4:5:6) TRANS_STATUS, ISHOP_LOGIN_IND, EMAIL_ADDR_AT_SIGN, TEL_NO_INT_PREFIX, REFUND_APPLICABLE_IND, REFUNDED_IND, CSP_IND RETURNING: 7: 8: 9,: 10,: 11,: 12,: 13; END;

    [165] insert link param 1: test

    [166] insert link param 2: you

    [167] insert link param 3: 2014-10-16 21:37:09.0

    [168] insert link param 4: your

    [169] insert link param 5: you

    [170] insert link param 6: N

    OracleSQLBuilderImpl.doEntityDML [171] failed...

    [172] X / Open SQL State is: 99999

    [173] java.sql.SQLException: ORA-22816: feature not supported with RETURNING clause

    ORA-06512: at line 1

    at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:462)

    at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:405)

    at oracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:931)

    at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:481)

    at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:205)

    at oracle.jdbc.driver.T4C8Oall.doOALL(T4C8Oall.java:548)

    at oracle.jdbc.driver.T4CCallableStatement.doOall8(T4CCallableStatement.java:213)

    at oracle.jdbc.driver.T4CCallableStatement.executeForRows(T4CCallableStatement.java:1111)

    at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1488)

    at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:3769)

    at oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedStatement.java:3904)

    at oracle.jdbc.driver.OracleCallableStatement.executeUpdate(OracleCallableStatement.java:9417)

    at oracle.jdbc.driver.OraclePreparedStatementWrapper.executeUpdate(OraclePreparedStatementWrapper.java:1512)

    at oracle.jbo.server.OracleSQLBuilderImpl.doEntityDML(OracleSQLBuilderImpl.java:429)

    at oracle.jbo.server.EntityImpl.doDML(EntityImpl.java:8575)

    at oracle.jbo.server.EntityImpl.postChanges(EntityImpl.java:6816)

    at oracle.jbo.server.DBTransactionImpl.doPostTransactionListeners(DBTransactionImpl.java:3290)

    at oracle.jbo.server.DBTransactionImpl.postChanges(DBTransactionImpl.java:3093)

    at oracle.jbo.server.DBTransactionImpl.commitInternal(DBTransactionImpl.java:2097)

    at oracle.jbo.server.DBTransactionImpl.commit(DBTransactionImpl.java:2378)

    at oracle.adf.model.bc4j.DCJboDataControl.commitTransaction(DCJboDataControl.java:1615)

    at oracle.adf.model.binding.DCDataControl.callCommitTransaction(DCDataControl.java:1417)

    at oracle.jbo.uicli.binding.JUCtrlActionBinding.doIt(JUCtrlActionBinding.java:1437)

    at oracle.adf.model.binding.DCDataControl.invokeOperation(DCDataControl.java:2150)

    at oracle.jbo.uicli.binding.JUCtrlActionBinding.invoke(JUCtrlActionBinding.java:740)

    at oracle.jbo.uicli.jui.JUActionBinding.actionPerformed(JUActionBinding.java:193)

    at oracle.jbo.uicli.controls.JUNavigationBar.doAction(JUNavigationBar.java:412)

    at oracle.jbo.jbotester.NavigationBar.doAction(NavigationBar.java:111)

    to oracle.jbo.uicli.controls.JUNavigationBar$ NavButton.actionPerformed (JUNavigationBar.java:118)

    at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1995)

    in javax.swing.AbstractButton$ Handler.actionPerformed (AbstractButton.java:2318)

    at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:387)

    at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:242)

    at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:236)

    at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:272)

    at java.awt.Component.processMouseEvent(Component.java:6289)

    at javax.swing.JComponent.processMouseEvent(JComponent.java:3267)

    at java.awt.Component.processEvent(Component.java:6054)

    at java.awt.Container.processEvent(Container.java:2041)

    at java.awt.Component.dispatchEventImpl(Component.java:4652)

    at java.awt.Container.dispatchEventImpl(Container.java:2099)

    at java.awt.Component.dispatchEvent(Component.java:4482)

    at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4577)

    at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4238)

    at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4168)

    at java.awt.Container.dispatchEventImpl(Container.java:2085)

    at java.awt.Window.dispatchEventImpl(Window.java:2478)

    at java.awt.Component.dispatchEvent(Component.java:4482)

    at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:644)

    to java.awt.EventQueue.access$ 000 (EventQueue.java:85)

    in java.awt.EventQueue$ 1.run(EventQueue.java:603)

    in java.awt.EventQueue$ 1.run(EventQueue.java:601)

    at java.security.AccessController.doPrivileged (Native Method)

    in java.security.AccessControlContext$ 1.doIntersectionPrivilege(AccessControlContext.java:87)

    in java.security.AccessControlContext$ 1.doIntersectionPrivilege(AccessControlContext.java:98)

    in java.awt.EventQueue$ 2.run(EventQueue.java:617)

    in java.awt.EventQueue$ 2.run(EventQueue.java:615)

    at java.security.AccessController.doPrivileged (Native Method)

    in java.security.AccessControlContext$ 1.doIntersectionPrivilege(AccessControlContext.java:87)

    at java.awt.EventQueue.dispatchEvent(EventQueue.java:614)

    at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)

    at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)

    at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)

    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)

    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)

    at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)

    [174] OracleSQLBuilder: ROLLBACK WORK point registration "BO_SP".

    [175] DCBindingContainer.reportException: oracle.jbo.DMLException

    oracle.jbo.DMLException [176]: Houston-26041: could not publish data from database in "Insert": SQL statement ' BEGIN INSERT INTO TRACK_TRANSACTION_STATUS_BIZ (TRANS_NO, TRANS_ID, START_DATE, LOGIN_USER_ID, SESSION_ID, REFUND_APPLICABLE_IND) VALUES (: 1,: 2,: 3,: 4: 5:6) TRANS_STATUS, ISHOP_LOGIN_IND, EMAIL_ADDR_AT_SIGN, TEL_NO_INT_PREFIX, REFUND_APPLICABLE_IND. , REFUNDED_IND, CSP_IND INTO TURNING: 7: 8: 9: 10: 11:12:13; END; ».

    at oracle.jbo.server.OracleSQLBuilderImpl.doEntityDML(OracleSQLBuilderImpl.java:583)

    at oracle.jbo.server.EntityImpl.doDML(EntityImpl.java:8575)

    at oracle.jbo.server.EntityImpl.postChanges(EntityImpl.java:6816)

    at oracle.jbo.server.DBTransactionImpl.doPostTransactionListeners(DBTransactionImpl.java:3290)

    at oracle.jbo.server.DBTransactionImpl.postChanges(DBTransactionImpl.java:3093)

    at oracle.jbo.server.DBTransactionImpl.commitInternal(DBTransactionImpl.java:2097)

    at oracle.jbo.server.DBTransactionImpl.commit(DBTransactionImpl.java:2378)

    at oracle.adf.model.bc4j.DCJboDataControl.commitTransaction(DCJboDataControl.java:1615)

    at oracle.adf.model.binding.DCDataControl.callCommitTransaction(DCDataControl.java:1417)

    at oracle.jbo.uicli.binding.JUCtrlActionBinding.doIt(JUCtrlActionBinding.java:1437)

    at oracle.adf.model.binding.DCDataControl.invokeOperation(DCDataControl.java:2150)

    at oracle.jbo.uicli.binding.JUCtrlActionBinding.invoke(JUCtrlActionBinding.java:740)

    at oracle.jbo.uicli.jui.JUActionBinding.actionPerformed(JUActionBinding.java:193)

    at oracle.jbo.uicli.controls.JUNavigationBar.doAction(JUNavigationBar.java:412)

    at oracle.jbo.jbotester.NavigationBar.doAction(NavigationBar.java:111)

    to oracle.jbo.uicli.controls.JUNavigationBar$ NavButton.actionPerformed (JUNavigationBar.java:118)

    at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1995)

    in javax.swing.AbstractButton$ Handler.actionPerformed (AbstractButton.java:2318)

    at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:387)

    at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:242)

    at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:236)

    at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:272)

    at java.awt.Component.processMouseEvent(Component.java:6289)

    at javax.swing.JComponent.processMouseEvent(JComponent.java:3267)

    at java.awt.Component.processEvent(Component.java:6054)

    at java.awt.Container.processEvent(Container.java:2041)

    at java.awt.Component.dispatchEventImpl(Component.java:4652)

    at java.awt.Container.dispatchEventImpl(Container.java:2099)

    at java.awt.Component.dispatchEvent(Component.java:4482)

    at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4577)

    at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4238)

    at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4168)

    at java.awt.Container.dispatchEventImpl(Container.java:2085)

    at java.awt.Window.dispatchEventImpl(Window.java:2478)

    at java.awt.Component.dispatchEvent(Component.java:4482)

    at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:644)

    to java.awt.EventQueue.access$ 000 (EventQueue.java:85)

    in java.awt.EventQueue$ 1.run(EventQueue.java:603)

    in java.awt.EventQueue$ 1.run(EventQueue.java:601)

    at java.security.AccessController.doPrivileged (Native Method)

    in java.security.AccessControlContext$ 1.doIntersectionPrivilege(AccessControlContext.java:87)

    in java.security.AccessControlContext$ 1.doIntersectionPrivilege(AccessControlContext.java:98)

    in java.awt.EventQueue$ 2.run(EventQueue.java:617)

    in java.awt.EventQueue$ 2.run(EventQueue.java:615)

    at java.security.AccessController.doPrivileged (Native Method)

    in java.security.AccessControlContext$ 1.doIntersectionPrivilege(AccessControlContext.java:87)

    at java.awt.EventQueue.dispatchEvent(EventQueue.java:614)

    at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)

    at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)

    at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)

    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)

    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)

    at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)

    Caused by: java.sql.SQLException: ORA-22816: feature not supported with RETURNING clause

    ORA-06512: at line 1

    at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:462)

    at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:405)

    at oracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:931)

    at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:481)

    at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:205)

    at oracle.jdbc.driver.T4C8Oall.doOALL(T4C8Oall.java:548)

    at oracle.jdbc.driver.T4CCallableStatement.doOall8(T4CCallableStatement.java:213)

    at oracle.jdbc.driver.T4CCallableStatement.executeForRows(T4CCallableStatement.java:1111)

    at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1488)

    at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:3769)

    at oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedStatement.java:3904)

    at oracle.jdbc.driver.OracleCallableStatement.executeUpdate(OracleCallableStatement.java:9417)

    at oracle.jdbc.driver.OraclePreparedStatementWrapper.executeUpdate(OraclePreparedStatementWrapper.java:1512)

    at oracle.jbo.server.OracleSQLBuilderImpl.doEntityDML(OracleSQLBuilderImpl.java:429)

    ... 52 more

    # # 0 in detail

    java.sql.SQLException: ORA-22816: feature not supported with RETURNING clause

    ORA-06512: at line 1

    Ask for help in this regard

    ADF will generate default DML statement with RETURNING clause, and it is not applicable to your use case: ORA-22816: feature not supported with RETURNING clause

    Instead, you can try with setUseReturningClause (false): http://docs.oracle.com/middleware/1213/adf/develop/adf-bc-entity-objects.htm#BABJAJCA

    Dario

  • ORA-01578: block of data corrupted ORACLE ORA-01110: data file 46:, ORA-06512: at line 1 ScanningError 1038246

    We get error below of the application team. Please find attached the file backup rman error.

    ORA-01578: ORACLE corrupt data (file # 46, block # 64626) ORA-01110: data file 46: ' / db04_hlt/PHCLMDB/PHCLMDB_DATA/phclm21.dbf' ORA-06512: at "HCLM_ADMIN. SCANPROC_INSUPLOADTEMP", line 16 ORA-06512: at line 1 ScanningError 1038246

    fe40282660394026b5f76bf3f5d649e4 SCANPROC_INSUPLOADTEMP-ORA-01578: data block (file # 46, block # 64626) corrupted ORACLE ORA-01110: data file 46:

    Hello

    Please follow the steps to format corrupt block a used the procedure mentioned in the document below, please note that you need to do several times for all the block corrupted in free space.
    Doc-ID 336133.1===> how corrupt Format block is not part of any Segment.

    Following the notes 293515.1 -->> ORA-1578 ORA-26040 in a LOB segment - Script to resolve errors

    This note is for these errors, but the procedure is exactly the same, we must:

    1 - identify the ROWID affected
    2 - Put the ROWID corrupted on EMPTY_LOB
    3. When you MOVE the LOB to a new Tablespace

    These are essentially the steps, the note shows how

    Kind regards

    Alok

  • Unit test: disassembly of the table or restore the line failed: ORA-06502: PL/SQL: digital error or value: string buffer too small ORA-06512: at line 22

    Is any idea available in the process of disassembly of the table or restore the line to line 22?

    I see a bunch of discussions on the subject, but no clear solution/answer...

    What could be the causes of this error?

    I had two process of disassembly on the level now, and one of them had failed with this error. Displacement of the failure of the process of disassembly compared to the level of the suite for the level of performance of test unit solved the error for a while, but after some more dragging the process of disassembly of the table (with about 500 cases) is permanent.

    Please advise...

    Thank you

    Val

    Well, had to create a bug officially... I hope this helps...

    Bug 19696042 : UNIT TEST: disassembly of THE TABLE or LINE RESTORE failed: ORA-06502: STRING BUFFER TOO SMA

    Thank you

    Val

  • ORA-06502: PL/SQL: digital or value error ORA-06512: at the 'APPS '. WF_NOTIFICATION', line 5754 ORA-06512: at line 5

    Hello

    I have a l_body variable in my pl/sql code with varchar2 (32767).

    It displays maximum 44 lines, more than 44 lines he gives buffer size error.

    If I use the clob data type then it gives value or digital erro on 44 lines.

    code is below

    concerning

    l_clob CLOB.

    l_body varchar2 (32767);

    BEGIN
    Dbms_lob. CreateTemporary (l_clob,TRUE);

    l_body: = null;

    l_body: =
    "< Html >";

    l_body: = l_body |
    "< Body >" ;

    -l_body: = l_body | "< do Face ="Verdana, Arial, Helvetica"Color ="#000000"> ';

    -l_body: = l_body | "< BR > < BR > < BR > ' | l_str | "< Br >".

    l_body: = l_body |
    "< BR >" || "Please note that receipt number < B > ' " || Trans_Id | ' with amount: ' | Trim (to_char (total_amount,'999G999G999G999D99')): ' < /B > has been sent for approval. Detail is given below:' | ' < Br BR > > < ' ;

    --------------------------


    l_body: = l_body |
    ' < / table > < Br > < Br > ' ;

    l_body: = l_body |
    '< table Border = 1 ">' ;

    -l_body: = l_body | "< Tr Bgcolor = rgb (0,154,61) > ';

    l_body: = l_body |
    "< Tr Bgcolor = rgb (162,202,230) >" ;

    l_body: = l_body |
    '< e > < P > < Font Size = 2 Face = "Verdana, Arial, Helvetica" > < div align = left > Date' ;

    l_body: = l_body |
    ' < e > < P > < Font Size = 2 Face = "Verdana, Arial, Helvetica" > < div align = left > name of the seller ' ;

    l_body: = l_body | '< e > < P > < Font Size = 2 Face = "Verdana, Arial, Helvetica" > < div align = left > number of PO' ;

    l_body: = l_body |
    ' < e > < P > < Font Size = 2 Face = "Verdana, Arial, Helvetica" > < div align = left > number ' ;

    l_body: = l_body | '< e > < P > < Font Size = 2 Face = "Verdana, Arial, Helvetica" > < div align = left > line' ;

    l_body: = l_body |
    '< e > < P > < Font Size = 2 Face = "Verdana, Arial, Helvetica" > < div align = left > Description of the object' ;

    l_body: = l_body |
    ' < e > < P > < Font Size = 2 Face = "Verdana, Arial, Helvetica" > < div align = left > quantity ' ;

    l_body: = l_body |
    ' < e > < P > < Font Size = 2 Face = "Verdana, Arial, Helvetica" > < div align = left > unit ' ;

    l_body: = l_body |
    ' < e > < P > < Font Size = 2 Face = "Verdana, Arial, Helvetica" > < div align = left > unit price PO' ;

    l_body: = l_body |
    ' < e > < P > < Font Size = 2 Face = "Verdana, Arial, Helvetica" > < div align = left > currency " " ;

    l_body: = l_body |
    ' < e > < P > < Font Size = 2 Face = "Verdana, Arial, Helvetica" > < div align = left > amount ' ;

    l_body: = l_body |
    '< e > < P > < Font Size = 2 Face = "Verdana, Arial, Helvetica" > < div align = left > Code combination' ;

    l_body: = l_body |
    "< /Tr >" ;

    FOR x in C LOOP

    l_body: = l_body | "< Tr >" ;

    l_body: = l_body |
    '< td > < P > < Font Size = 2 > < div align = left >' | x.transaction_date | "< Table >" ;

    l_body: = l_body |
    '< td > < P > < Font Size = 2 > < div align = left >' | x.VENDOR_NAME | "< Table >" ;

    l_body: = l_body |
    '< td > < P > < Font Size = 2 > < div align = left >' | x.po_number | "< Table >" ;

    l_body: = l_body |
    '< td > < P > < Font Size = 2 > < div align = left >' | x.release_num | "< Table >" ;

    l_body: = l_body | '< td > < P > < Font Size = 2 > < div align = left >' | x.line_num | "< Table >" ;

    l_body: = l_body |
    '< td > < P > < Font Size = 2 > < div align = left >' | x.item_description | "< Table >" ;

    l_body: = l_body |
    '< td > < P > < Font Size = 2 > < div align = right >' | x.Quantity | "< Table >" ;

    l_body: = l_body | '< td > < P > < Font Size = 2 > < div align = left >' | x.unit_of_measure | "< Table >" ;

    l_body: = l_body |
    '< td > < P > < Font Size = 2 > < div align = right >' | x.po_unit_price | "< Table >" ;

    l_body: = l_body |
    '< td > < P > < Font Size = 2 > < div align = left >' | x.currency_code | "< Table >" ;

    l_body: = l_body |
    '< td > < P > < Font Size = 2 > < div align = right >' | x.amount | "< Table >" ;

    l_body: = l_body |
    '< td > < P > < Font Size = 2 > < div align = left >' || x.cc|| "< Table >" ;

    l_body: = l_body |
    "< /Tr >" ;

    END LOOP;

    l_body: = l_body |
    ' < / table > < Br > < Br > ' ;

    l_body: = l_body |
    "< / body >" || CHR(10);

    l_body: = l_body |
    ' < / html > ' || CHR(10);

    DBMS_LOB. WriteAppend (l_clob, length (l_body), l_body);

    RETURN L_Clob;

    END Format_Notification_Msg;

    The maximum size allowed for l_body is 32767 who as varchar2 (32767)

    Even if the CLOB has no size limit, you store the actual data in "l_body", it throws the error when the "l_body" increases of 32,767 characters.

    Call the dbms_lob.writeappend () API in the for loop and cancel l_body after the API call, so that the 'l_body' will not go beyond the specified limit.

  • ERROR at line 1: ORA-06502: PL/SQL: digital or value error ORA-06512: at line 10

    Hi all

    DECLARE

    TYPE (t1) IS RENDERING

    v_ename emp.ename%TYPE,

    v_sal emp.sal%TYPE

    );

    TNom TYPE IS an ARRAY OF t1

    INDEX OF DIRECTORY;

    v_tname tNom;

    BEGIN

    BECAUSE me IN v_tname. FIRST... v_tname. LAST

    LOOP

    Dbms_output.put_line (v_tname (i) .v_ename |) '' || .v_sal v_tname (i));

    END LOOP;

    END;

    You want to ask why I used the SLIDER? -We can use in BULK COLLECT with LIMIT clause with the cursor

    We also directly in bulk collect into collections as below:

    DECLARE

    TYPE (t1) IS RENDERING

    v_ename emp.ename%TYPE,

    v_sal emp.sal%TYPE

    );

    TNom TYPE IS an ARRAY OF t1

    INDEX OF DIRECTORY;

    v_tname tNom;

    BEGIN

    SELECT ename, sal BULK COLLECT INTO v_tname FROM emp;

    BECAUSE me IN v_tname. FIRST... v_tname. LAST

    LOOP

    Dbms_output.put_line (v_tname (i) .v_ename |) ' ' || .v_sal v_tname (i));

    END LOOP;

    END;

    /

  • How to solve the problem of the ORA-29273 and ORA-06512

    Hey, guys:

    I had a problem to get Google geocoding when I used a government licensed Google API key. This project is developed for the Government, so we should be able to use this API key. And the agent of the Government told me that as long as I use this API key and they add to the area of our company to their list, we should be able to get free Google geocoding indefinitely. I'm using Oracle 11 g 2, Apex 4.1. Google returns a result (1600 geocoding) and after awhile my program was exception. However, I got the following problem:

    ORA-29273: HTTP request failed
    ORA-06512: at "SYS." UTL_HTTP", line 1722
    ORA-29259: end-of-input reached
    ORA-06512: at "get OUT. SOR_TEST_SERVICE', line 24
    ORA-06512: at "get OUT. SOR_TEST_SERVICE', line 187
    ORA-06512: at line 6
    29273 00000 - "the HTTP request failed.
    * Cause: The UTL_HTTP package cannot run the HTTP request.
    * Action: Use get_detailed_sqlerrm to check the detailed error message.
    Correct the error and restart the HTTP request.

    and I searched online and found the thread following OTN:

    Anyone incorporating the Google Apps Provisioning via Oracle or APEX API?

    It looks like, I have to get Google API certificate and install it on Oracle wallet. I do not experience this issue. Can someone give me a roadmap to this topic? For example, how can I get a certificate of Google? Should I get in touch with Google, or send the request with API license key? or API key is a certificate? an example would be very useful!


    Here is my code
      procedure Get_Geocoding(P_s_Address in varchar2, P_s_Geocoding out varchar2, P_n_accuracy out number, P_b_success out boolean) is
      
      l_address varchar2(4000);
      l_url varchar2(32000);
      l_response varchar2(3200);
      n_first_comma number;
      n_second_comma number;
      n_level_length number;
      
      BEGIN
        /* TODO implementation required */
        
        l_address:=APEX_UTIL.URL_ENCODE(P_s_Address);
        l_address := replace(l_address,' ','+');
         
        l_url := 'http://maps.google.com/maps/geo?q='||l_address||'&'||'output=csv'||'&'||'key=my API key';
        l_response := utl_http.request(l_url, APEX_APPLICATION.G_PROXY_SERVER);
        
        --dbms_output.put_line(l_response);
        
        n_first_comma:=instr(l_response,',',1,1);
        n_second_comma:=instr(l_response,',',1,2);
        n_level_length:=n_second_comma-n_first_comma-1;
    
        P_n_accuracy:=to_number(substr(l_response,n_first_comma+1, n_level_length));
        
         l_response:=substr(l_response,instr(l_response,',',1,2)+1);
        
           
        
        P_s_Geocoding:=l_response;
        if (P_s_Geocoding<>'0,0') then
          P_b_success:=true;
         else
          P_b_success:=false;
        end if;
      
      END;
    Thank you very much!

    Sam

    Published by: lxiscas on August 22, 2012 16:33

    Published by: lxiscas on August 23, 2012 08:27

    To access the HTTPS site, you will need portfolio information.
    Portfolio is created through the Oracle Wallet Manager. It is available in standard edition database or Oracle HTTP server.
    If you have installed, go to Oracle Wallet Manager and create a portfolio.
    Then, you need to import the certificates on this portfolio.

    When you open the https://maps.google.com/ website in your web browser, you will see a lock symbol just before https. Double click on that and click on certificate information.
    Then click path of certificate, and then click the top node and click View Certificate and click on details and then copy in the file. The Certificate Export Wizard will start select
    Message Syntax cryptographice and check include all certification path.

    He followed even for all nodes in the main certificate

    This will create a file. Once the file is created. Double click on that and start the Certificate Import Wizard. Follow the online instructions. (It is need in the server)
    Once done. Open the Oracle Portfolio Manager and import it there also. Right-click on the wallet, and select Import.
    Then log in as administrator of the apex
    Workspace - internal
    User - Admin
    Password - passowrd you created everything by the installation

    Go to the setting of the instance and select portfolio information. And put the path of the portfolio in the file format: and password wallet.

    Once done, I think that you will be able to access.

    See you soon,.
    Mehabub

  • ORA-06512: at "OLAPSYS. CWM2_OLAP_UTILITY', line 1865

    Hello

    I'm changing the description of a mesuares in an existing cube.

    I executed the following command.

    run cwm2_olap_measure.set_short_description ("'REFMNE', 'CUBE_VENTES', 'VTE_MT_PR', ' sales ');

    I get the following error:

    ORA-06510: PL/SQL: not supported by the user-defined exception
    ORA-06512: at "OLAPSYS. CWM2_OLAP_UTILITY', line 1865
    ORA-01403: no data found
    ORA-06512: at "OLAPSYS. CWM2_OLAP_MEASURE', line 19
    ORA-06512: at "OLAPSYS. CWM2_OLAP_MEASURE', line 30
    ORA-06512: at "OLAPSYS. CWM2_OLAP_MEASURE', line 192
    ORA-06512: at line 1

    I checked all my comments
    The procedure is defined as set_short_description (p_Cube_Owner varchar2-"REFMNE" - is the owner of the schema
    , p_Cube_Name varchar2-"CUBE_VENTES".
    , p_Measure_Name varchar2-"VTE_MT_PR".
    p_Short_Description varchar2); -' Sales amount '.


    This cube has been created using template xml via AWM and the cube works very well. The database is 11.2.0.1.0. I'm running the statement as the owner of work/cube space

    Any ideas awm. I need to change the description of each object in the workspace.

    Thank you

    The cwm2_olap_measure package and any other that begines with MCG, is frowned upon in 11.2. AWM does not use this API to create cubes. If you have created your cube in AWM then you need to use dbms_cube.import_xml (if you are dealing with a style of 11g AW) or dbms_aw_xml.execute (if you are dealing with a 10g AW style). You can also use documented interfaces for Java ('OLAP API' and 'AWXML' for 11g and 10g respectively).

  • Why ORA-06512: at "SYS." DBMS_SCHEDULER', line 1794

    Hi, I do the following

    -creation of a beginning of program
    BEGIN
    () dbms_scheduler.create_program
    program name = > "MAINTAIN_DDI_PROGRAM"
    program_type = > 'procedure_stockee ',.
    program_action = > 'MAINTAIN_DDI ',.
    number_of_arguments = > 1,
    activated = > FALSE,
    Comments = > 'MAINTAIN_DDI');
    END;
    /
    -creation of a program end

    -set the program argument starts
    BEGIN
    () dbms_scheduler.define_program_argument
    program name = > "MAINTAIN_DDI_PROGRAM"
    argument_name = > 'p_User ',.
    argument_position = > 1,
    argument_type = > 'VARCHAR2 ',.
    default_value = > 'SYSTEM');
    END;
    /
    -end of the argument to define program

    -creation of schedules departure
    Start
    () DBMS_SCHEDULER.create_schedule
    schedule_name = > "MAINTAIN_DDI_SCHEDULE"
    start_date = > SYSTIMESTAMP,
    repeat_interval = > ' FREQ = DAILY; BYHOUR = 0',
    End_date = > ",
    Comments = > 'MAINTAIN_DDI_SCHEDULE_COMMENTS');
    end;
    /

    -creation of end times

    -creation of the beginning of the task
    Start

    DBMS_SCHEDULER. () CREATE_JOB
    job_name = > 'MAINTAIN_DDI_JOB ',.
    program name = > "MAINTAIN_DDI_PROGRAM"
    schedule_name = > 'MAINTAIN_DDI_SCHEDULE');

    () DBMS_SCHEDULER.set_attribute
    name = > 'MAINTAIN_DDI_JOB ',.
    attribute = > "job_class"
    value = > "daily_job_class");

    end;
    /
    -activation of the start of work
    SQL > exec DBMS_SCHEDULER. SELECT ("MAINTAIN_DDI_JOB");
    DBMS_SCHEDULER BEGIN. SELECT ("MAINTAIN_DDI_JOB"); END;

    *
    ERROR on line 1:
    ORA-27486: insufficient privileges
    ORA-06512: at "SYS." DBMS_ISCHED', line 2751
    ORA-06512: at "SYS." DBMS_SCHEDULER', line 1794
    ORA-06512: at line 1
    -end of jobs

    ---

    -> Why don't I have this error?

    SQL > select distinct privilege of user_sys_privs;

    PRIVILEGE
    ----------------------------------------
    CREATE JOBS
    UNLIMITED TABLESPACE
    MANAGE SCHEDULER

    = > cannot be doesn't have enough privileges listed in the Administrator's Guide to Oracle database on pg 27-2

    to turn on work, I just need to own.

    SELECT job_name, job_type, job_action, owner, system, activated from all_scheduler_jobs;

    OWNER JOB_NAME J JOB_ACTION SYSTEM ENABL
    -------- ----------------------- - ------------------------------ ----- -----
    PROCMASK MAINTAIN_DDI_JOB_2 TRUE FALSE
    PROCMASK MAINTAIN_DDI_JOB FALSE FALSE

    So I created another job using a program named with the same name of program but no schedule_name

    BEGIN
    DBMS_SCHEDULER. () CREATE_JOB
    job_name = > 'MAINTAIN_DDI_JOB_2 ',.
    program name = > "MAINTAIN_DDI_PROGRAM"
    repeat_interval = > ' FREQ = DAILY; BYHOUR = 12',
    Comments = > "every day at noon");
    END;
    /

    DBMS_SCHEDULER exec. SELECT ("MAINTAIN_DDI_JOB_2");

    Why am I able to allow a job created a program called aid, but not able to allow a job using a program named creation and a calendar of name?

    Thank you very much!

    Published by: oraclewannabe2 on September 23, 2008 20:55

    Hello

    You probably need to grant access to the owner of the task running on the job class.

    Login as SYS or the creator of the category of jobs and

    Grant execute on sys.daily_job_class to job_owner;

    Hope this helps,
    Ravi.

  • ORA-06533: index beyond County ORA-06512:

    Hello

    I tried to insert the collection of data (below) in two individual tables, when I tried to insert a unique collection of data in two individual tables, it has been introduced.

    But when I tired to insert several collections into two individual tables, I am getting below error.

    Einf is my PLSQL CODE with details of the error,

    could you please give me solution.

    Thanks in advance .

    Set serveroutput on

    DECLARE

    /*

    PL ORG_ADDRESSES_PHONES_TAB: = ORG_ADDRESSES_PHONES_TAB (ORG_ADDRESSES_PHONES_TYPE ('a1', 'c1', 's1', 'p1', 1, ORG_PHONES_TAB (ORG_PHONES_TYPE ('a2', 'p1', 's1', 'e1')));)

    If inserted unique collections

    */

    ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

    ------------------------------------------------------------------------          But Below data is not inserting because of multiple collections          ----------------------------------------------------------------------------------------------

    ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

    PL ORG_ADDRESSES_PHONES_TAB: = ORG_ADDRESSES_PHONES_TAB (ORG_ADDRESSES_PHONES_TYPE ("a1", "c1", "s1", "p1", 1, ORG_PHONES_TAB (ORG_PHONES_TYPE ("a2", "p1", "s1", "e1"))), ORG_ADDRESSES_PHONES_TYPE ('a2', 'c2', 's3', 'p4', 2, ORG_PHONES_TAB (ORG_PHONES_TYPE ('d3', 'f3', 'ws3', 're3')));)

    BEGIN

    I'm IN pl. FIRST... LAST pl.

    LOOP

    PL. EXTEND;

    dbms_output.put_line (i);

    dbms_output.put_line ('next': pl (i) .ORG_PHONES.) Next (1));

    PL of YEW. (I) exists, THEN - if the element exists then display

    dbms_output.put_line (' ADDRESS ': pl (i).) ADDRESS);

    dbms_output.put_line (' CITY ' | pl (i).) IN TOWN);

    dbms_output.put_line ('STATE_CODE' | pl (i).) STATE_CODE);

    dbms_output.put_line (' zip_code ' | pl (i).) ZIP_CODE);

    dbms_output.put_line ('PRIMARY_YESNO': (i) pl.) PRIMARY_YESNO);

    dbms_output.put_line ('POSTAL Code': pl (i) .ORG_PHONES (i).) AREA CODE);

    dbms_output.put_line ('PREFIX': pl (i) .ORG_PHONES (i).) PREFIX);

    dbms_output.put_line ('SUFFIX' | pl (i) .ORG_PHONES (i).) SUFFIX);

    dbms_output.put_line ('EXTENSION' | pl (i) .ORG_PHONES (i).) EXTENSION);

    -pl. EXTEND;

    -pl (i) .ORG_PHONES. EXTEND;

    END IF;

    PL (i) .ORG_PHONES. EXTEND;

    END LOOP;

    COMMIT;

    -dbms_output.put_line ('hii');

    end;

    ----------------------------------------

    Failed query see the settings

    Error from line: 3 in command.

    DECLARE

    -declare a variable of type projecttable

    PL ORG_ADDRESSES_PHONES_TAB: = ORG_ADDRESSES_PHONES_TAB (ORG_ADDRESSES_PHONES_TYPE ("a1", "c1", "s1", "p1", 1, ORG_PHONES_TAB (ORG_PHONES_TYPE ("a2", "p1", "s1", "e1"))), ORG_ADDRESSES_PHONES_TYPE ('ta2', 'uc2', 'vs3', 'wp4', 2, ORG_PHONES_TAB (ORG_PHONES_TYPE ('d3', 'f3', 'ws3', 're3')));)

    -How to display the values in the table

    BEGIN - beginning of the main block

    I'm in pl.first... pl. Last

    loop

    dbms_output.put_line (i);

    dbms_output.put_line (' ADDRESS ': pl (i).) ADDRESS);

    dbms_output.put_line (' CITY ' | pl (i).) IN TOWN);

    dbms_output.put_line ('STATE_CODE' | pl (i).) STATE_CODE);

    dbms_output.put_line (' zip_code ' | pl (i).) ZIP_CODE);

    dbms_output.put_line ('PRIMARY_YESNO': (i) pl.) PRIMARY_YESNO);

    dbms_output.put_line ('POSTAL Code': pl (i) .ORG_PHONES (i).) AREA CODE);

    dbms_output.put_line ('PREFIX': pl (i) .ORG_PHONES (i).) PREFIX);

    dbms_output.put_line ('SUFFIX' | pl (i) .ORG_PHONES (i).) SUFFIX);

    dbms_output.put_line ('EXTENSION' | pl (i) .ORG_PHONES (i).) EXTENSION);

    -pl. EXTEND;

    PL (i) .ORG_PHONES. EXTEND;

    end loop;

    COMMIT;

    -dbms_output.put_line ('hii');

    end;

    Error report-

    ORA-06533: index beyond County

    ORA-06512: at line 19

    06533 00000 - 'County beyond index'

    * Cause: A limit index was greater than the number of a varray

    or too big for a nested table.

    * Action: Verify program logic and extend explicitly if necessary.

    1

    ADDRESS a1

    CITY c1

    STATE_CODE s1

    Zip_code p1

    PRIMARY_YESNO 1

    CODEZONE a2

    PREFIX p1

    SUFFIX s1

    E1 EXTENSION

    2

    ADDRESS ta2

    Uc2 CITY

    STATE_CODE vs3

    Zip_code wp4

    PRIMARY_YESNO 2

    You have to LOOP in your table of pl (I) .ORG_PHONES (I)

    CREATE OR REPLACE PROCEDURE myproc AS
    
       pl ORG_ADDRESSES_PHONES_TAB := ORG_ADDRESSES_PHONES_TAB(ORG_ADDRESSES_PHONES_TYPE('a1'
                                                                                        ,'c1'
                                                                                        ,'s1'
                                                                                        ,'p1'
                                                                                        ,1
                                                                                        ,ORG_PHONES_TAB(ORG_PHONES_TYPE('a2'
                                                                                                                       ,'p1'
                                                                                                                       ,'s1'
                                                                                                                       ,'e1')
                                                                                                       )
                                                                                       )
                                                              ,ORG_ADDRESSES_PHONES_TYPE('a2'
                                                                                        ,'c2'
                                                                                        ,'s3'
                                                                                        ,'p4'
                                                                                        ,2
                                                                                        ,ORG_PHONES_TAB(ORG_PHONES_TYPE('d3'
                                                                                                                       ,'f3'
                                                                                                                       ,'ws3'
                                                                                                                       ,'re3')
                                                                                                       )
                                                                                        )
                                                              );
    
    BEGIN
    
       DBMS_OUTPUT.PUT_LINE('First: ' || TO_CHAR(pl.FIRST));
       DBMS_OUTPUT.PUT_LINE('Last: ' || TO_CHAR(pl.LAST));
    
       FOR I IN pl.FIRST..pl.LAST LOOP
    
          pl.EXTEND;
    
          DBMS_OUTPUT.PUT_LINE(I);
          DBMS_OUTPUT.PUT_LINE('next ' || pl(I).ORG_PHONES.NEXT(1));
    
          IF(pl.EXISTS(I)) THEN                       -- if item exists then display
    
             DBMS_OUTPUT.PUT_LINE('ADDRESS  ' || pl(I).ADDRESS);
             DBMS_OUTPUT.PUT_LINE('CITY  ' || pl(I).CITY);
             DBMS_OUTPUT.PUT_LINE('STATE_CODE  ' || pl(I).STATE_CODE);
             DBMS_OUTPUT.PUT_LINE('POSTAL_CODE  ' || pl(I).POSTAL_CODE);
             DBMS_OUTPUT.PUT_LINE('PRIMARY_YESNO  ' || pl(I).PRIMARY_YESNO);
    
             FOR j IN pl(I).org_phones.FIRST..pl(I).org_phones.LAST LOOP
    
                DBMS_OUTPUT.PUT_LINE('AREACODE  ' || pl(I).ORG_PHONES(j).AREACODE);
                DBMS_OUTPUT.PUT_LINE('PREFIX  ' || pl(I).ORG_PHONES(j).PREFIX);
                DBMS_OUTPUT.PUT_LINE('SUFFIX  ' || pl(I).ORG_PHONES(j).SUFFIX);
                DBMS_OUTPUT.PUT_LINE('EXTENSION  ' || pl(I).ORG_PHONES(j).EXTENSION);
    
             END LOOP;
    
          --pl.EXTEND;
          --pl(i).ORG_PHONES.EXTEND;
    
          END IF;
    
          pl(I).ORG_PHONES.EXTEND;
    
       END LOOP;
    
       COMMIT;
    
       --dbms_output.put_line('hii');
    
    EXCEPTION
    
       WHEN OTHERS THEN
          DBMS_OUTPUT.PUT_LINE(DBMS_UTILITY.FORMAT_ERROR_STACK);
    
    END myproc;
    
  • ORA-12012: error on auto work 754461 ORA-29279: SMTP permanent error: ORA-29279: SMTP permanent error: 501 Syntax error, command parameters "RCPT TO:" ORA-06512 unrecognized or missing: at "SYS." UTL_SMTP", line 20 ORA-06512: at"SYS." UTL_SMTP.

    Hello


    I get below error frequently in the log database alerts.


    ORA-12012: error on auto work 754461

    ORA-29279: SMTP permanent error: ORA-29279: SMTP permanent error: 501 Syntax error, command parameters ' RCPT TO: ' unrecognized or missing

    ORA-06512: at "SYS." UTL_SMTP", line 20

    ORA-06512: at "SYS." UTL_SMTP", line 98

    ORA-06512: at "SYS." UTL_SMTP", line 240

    ORA-06512: at the 'APPS '. EIS_UTIL_PKG', line 94

    ORA-06512: at the 'APPS '. HKD_PO_ADDON_PKG', line 110

    ORA-06512: at line 1

    The syntax error comes from the SMTP server, not to the job itself, so I disagree with your solution.

  • I get the error message like "error - ORA-29273 report: failure of the HTTP ORA-06512: at"SYS. " UTL_HTTP", line 1130 ORA-12535: TNS:operation expired ORA-06512: 37 29273 line. 00000 - "HTTP request failed" * Cause: package UTL_HTTP The Impossible to run

    I have tried the code

    DECLARE

    lv_url VARCHAR2 (1000): = ' http://shenzhoufellowship.org/main2/files/old/SpecialTopics/TheLoveDare.pdf';

    lc_return BLOB;

    lhttp_url httpuritype.

    Varriables - declared to have written the LOB to pdf file-

    l_file UTL_FILE. TYPE_DE_FICHIER;

    l_buffer RAW (32767).

    l_amount directory: = 32767;

    l_pos INTEGER: = 1;

    l_blob BLOB;

    l_blob_len INTEGER.

    BEGIN

    -create URIs

    lhttp_url: = httpuritype.createuri (lv_url);

    -get the PDF document

    lc_return: = lhttp_url.getblob ();

    -Open the destination file.

    l_file: = UTL_FILE. FOPEN ('MBO_INPUT_DIR', 'MBD.zip', 'wb');

    -Get the total length of the BLOB

    l_blob_len: = DBMS_LOB.getlength (lc_return);

    -Pieces of the BLOB to read and write to the file

    -full up.

    While l_pos < l_blob_len LOOP

    DBMS_LOB. READ (lc_return, l_amount, l_pos, l_buffer);

    UTL_FILE.put_raw (l_file, l_buffer, FALSE);

    l_pos: = l_pos + l_amount;

    END LOOP;

    -Closes the file.

    UTL_FILE. FCLOSE (l_file);

    EXCEPTION

    WHILE OTHERS THEN

    -Close the file if something goes wrong.

    IF UTL_FILE.IS_OPEN (l_file) THEN

    UTL_FILE. FCLOSE (l_file);

    END IF;

    LIFT;

    END;

    But make a mistake like:

    Error report-

    ORA-29273: HTTP request failed

    ORA-06512: at "SYS." UTL_HTTP", line 1130

    ORA-12535: TNS:operation expired

    ORA-06512: at line 37 level

    29273 00000 - "the HTTP request failed.

    * Cause: The UTL_HTTP package cannot run the HTTP request.

    * Action: Use get_detailed_sqlerrm to check the detailed error message.

    Correct the error and restart the HTTP request.

    Please suggest a solution. Is it possible to download a zip file with the same code?

    [oracle@localhost ~]$ sqlplus scott/tiger
    
    SQL*Plus: Release 11.2.0.1.0 Production on Mon Apr 6 13:59:09 2015
    
    Copyright (c) 1982, 2009, Oracle.  All rights reserved.
    
    Connected to:
    Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    
    SQL> --My Database version
    SQL> ----------------------
    SQL> SELECT * FROM v$version;
    
    BANNER
    --------------------------------------------------------------------------------
    Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production
    PL/SQL Release 11.2.0.1.0 - Production
    CORE    11.2.0.1.0      Production
    TNS for Linux: Version 11.2.0.1.0 - Production
    NLSRTL Version 11.2.0.1.0 - Production
    
    SQL> ed
    Wrote file afiedt.buf
    
      1  DECLARE
      2        lv_url    VARCHAR2(500) := 'http://shenzhoufellowship.org/main2/files/old/SpecialTopics/TheLoveDare.pdf';
      3        lc_return BLOB;
      4        lhttp_url httpuritype;
      5        ---Varriables declared for writing the LOB to pdf file --
      6        l_file     UTL_FILE.FILE_TYPE;
      7        l_buffer   RAW(32767);
      8        l_amount   BINARY_INTEGER := 32767;
      9        l_pos      INTEGER := 1;
    10       l_blob     BLOB;
    11       l_blob_len INTEGER;
    12     BEGIN
    13       --create uri
    14       lhttp_url := httpuritype.createuri(lv_url);
    15       --get the PDF document
    16       lc_return := lhttp_url.getblob();
    17       -- Open the destination file.
    18       l_file := UTL_FILE.FOPEN('SAUBHIK', 'TheLoveDare.pdf', 'wb');
    19       --Get the total length of the BLOB
    20       l_blob_len := DBMS_LOB.getlength(lc_return);
    21       -- Read chunks of the BLOB and write them to the file
    22       -- until complete.
    23       WHILE l_pos < l_blob_len LOOP
    24         DBMS_LOB.READ(lc_return, l_amount, l_pos, l_buffer);
    25         UTL_FILE.put_raw(l_file, l_buffer, FALSE);
    26         l_pos := l_pos + l_amount;
    27       END LOOP;
    28       -- Close the file.
    29       UTL_FILE.FCLOSE(l_file);
    30     EXCEPTION
    31       WHEN OTHERS THEN
    32         -- Close the file if something goes wrong.
    33         IF UTL_FILE.IS_OPEN(l_file) THEN
    34           UTL_FILE.FCLOSE(l_file);
    35         END IF;
    36         RAISE;
    37*    END;
    38  /
    DECLARE
    *
    ERROR at line 1:
    ORA-29273: HTTP request failed
    ORA-06512: at "SYS.UTL_HTTP", line 1130
    ORA-24247: network access denied by access control list (ACL)
    ORA-06512: at line 36
    
    SQL> conn sys as sysdba
    Enter password:
    Connected.
    SQL> ed
    Wrote file afiedt.buf
    
      1  BEGIN
      2    DBMS_NETWORK_ACL_ADMIN.CREATE_ACL(acl         => 'love.xml',
      3                                      description => 'Love ACL',
      4                                      principal   => 'SCOTT',
      5                                      is_grant    => true,
      6                                      privilege   => 'connect');
      7    DBMS_NETWORK_ACL_ADMIN.ADD_PRIVILEGE(acl       => 'love.xml',
      8                                         principal => 'SCOTT',
      9                                         is_grant  => true,
    10                                         privilege => 'resolve');
    11    DBMS_NETWORK_ACL_ADMIN.ASSIGN_ACL(acl  => 'love.xml',
    12                                      host => 'shenzhoufellowship.org');
    13  commit;
    14* END;
    15  /
    
    PL/SQL procedure successfully completed.
    
    SQL> conn scott/tiger
    Connected.
    SQL> ed
    Wrote file afiedt.buf
    
      1  DECLARE
      2        lv_url    VARCHAR2(500) := 'http://shenzhoufellowship.org/main2/files/old/SpecialTopics/TheLoveDare.pdf';
      3        lc_return BLOB;
      4        lhttp_url httpuritype;
      5        ---Varriables declared for writing the LOB to pdf file --
      6        l_file     UTL_FILE.FILE_TYPE;
      7        l_buffer   RAW(32767);
      8        l_amount   BINARY_INTEGER := 32767;
      9        l_pos      INTEGER := 1;
    10       l_blob     BLOB;
    11       l_blob_len INTEGER;
    12     BEGIN
    13       --create uri
    14       lhttp_url := httpuritype.createuri(lv_url);
    15       --get the PDF document
    16       lc_return := lhttp_url.getblob();
    17       -- Open the destination file.
    18       l_file := UTL_FILE.FOPEN('SAUBHIK', 'TheLoveDare.pdf', 'wb');
    19       --Get the total length of the BLOB
    20       l_blob_len := DBMS_LOB.getlength(lc_return);
    21       -- Read chunks of the BLOB and write them to the file
    22       -- until complete.
    23       WHILE l_pos < l_blob_len LOOP
    24         DBMS_LOB.READ(lc_return, l_amount, l_pos, l_buffer);
    25         UTL_FILE.put_raw(l_file, l_buffer, FALSE);
    26         l_pos := l_pos + l_amount;
    27       END LOOP;
    28       -- Close the file.
    29       UTL_FILE.FCLOSE(l_file);
    30     EXCEPTION
    31       WHEN OTHERS THEN
    32         -- Close the file if something goes wrong.
    33         IF UTL_FILE.IS_OPEN(l_file) THEN
    34           UTL_FILE.FCLOSE(l_file);
    35         END IF;
    36         RAISE;
    37*    END;
    38  /
    
    PL/SQL procedure successfully completed.
    
    SQL> exit
    Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    [oracle@localhost ~]$ cd saubhik/
    [oracle@localhost saubhik]$ pwd
    /home/oracle/saubhik
    [oracle@localhost saubhik]$ ls -l *.pdf
    -rw-r--r-- 1 oracle oinstall 60055 Apr  6 14:03 TheLoveDare.pdf
    [oracle@localhost saubhik]$
    

    I love this pdf file. I would like to read this and mean while if you get an error then please post in its entirety and also think that it is an Oracle error or network.

  • ORA-01002: extraction out of sequence ORA-06512

    Hi team,

    I tried the below block to check out of it.

    I do not understand why the block below gives error ora-01002.

    Could you please advice on this.

    declare

    cursor c1 is select * from emp for update;

    z c1% rowtype;

    Start

    Open c1;

    Fetch c1 into z.

    commit;

    Fetch c1 into z.

    end;

    Thank you

    Your mistake himself say about your mistake and how to rectify

    You must check out inside a loop

    RA-01002: extraction out of sequence

    ORA-06512: at line 11 level

    01002 00000 - "fetch out of sequence.

    * Cause: This error means that a fetch tried a slider

    that is no longer valid.  Note that a PL/SQL cursor loop

    implicitly made extractions and so can also cause this error.

    There are a number of possible causes of this error, including:

    (1) extraction of a cursor after the last row has been recovered

    and the ORA-1403 error returned.

    (2) if the cursor has been opened with the FOR UPDATE clause,

    recovery after a COMMIT has been made will return the error.

    (3) the reallocation of the placeholders in the SQL statement, and then deliver

    before rerunning the fetch statement.

    * Action: 1) do not issue not a statement of extraction after the last line has been

    not recovered - there are no lines to retrieve.

    (2) do not issue a VALIDATION inside a loop of extraction of cursor

    the UPDATE that was opened.

    (3) rerun the statement after the rebinding, then try to

    search again.

    DECLARE

    CURSOR c1

    IS

    SELECT * FROM emp FOR UPDATE;

    z c1% rowtype;

    BEGIN

    OPEN c1;

    loop

    FETCH c1 INTO z.

    When exit c1% notfound;

    end loop;

    COMMIT;

    END;

  • Workspace Manager 11 GR 2: ORA-20145: "Under TENSION" workspace cannot be deleted ORA-06512

    Hi all

    I considered the possibility of use of the Workspace Manager on Oracle 11g 11.2.0.4 (Oracle Linux OS) as a way to allow developers to experiment in our Dev of the databases (s) on the changing data in application dev (for most code tables) schema support app. I used preview Workspace Manager Enterprise Manager 12 c against one of our Dev database after (briefly) examining the 2009 Oracle Database 11g and the more formal Workspace Manager Guide the developer 11g Release 2 (11.2).

    My initial work did not provide the correct results (do not ask for help on that), so I want to start by removing all child workspaces and workspace 'On-line'. However, when I try to use EM12C to remove the LIVE (which was created under SYS) workspace I get "ORA-20145: 'LIVE' workspace cannot be deleted ORA-06512: at the"WMSYS.LT", line 4994 ORA-06512: at line 2".»

    Before posting, I googled first, then questioned this forum and even the 'full search' option but have not found any other mention to this.

    Can someone help guide me to a fix? It's development, it is important for me as a DBA because it will help you avoid to create and maintain multiple copies of our data and application for each developer schemas.

    Thank you

    Ted

    I could have sworn that I replied to this a few hours ago.  Maybe the Web gremlins ate the post, maybe they will regurgitate a few hours (so apologies if it appears a second time).

    You can not remove the DIRECT workspace.  The DIRECT workspace still exists.  This is the workspace that you are in when you log in.  If you have a table without version 10 lines and activate the version, it will have 10 rows in the DIRECT workspace.  You can create children other areas of work where the table can have 9 lines or 11 and those that can be deleted, but can not be the DIRECT workspace.

    You can disable versioning on each of your tables (dbms_wm.disableVersioning) If you want to return to the State they were before that you have turned on versioning in the first place.

    Justin

  • OEM12c: Container of data in case of failure to schedule the backup-ORA 20411 - ORA-06512

    Oracle Enterprise Manager Cloud control 12 c - 12.1.0.3

    Oracle Database Enterprise Edition 11.2.0.3

    Oracle Enterprise Linux 5

    Database container:

    Oracle Database Enterprise Edition 12.1.0.5

    Windows Server 2012 R2 Standard

    OEM12c: Container for database fail to schedule backup

    ORA-20411: the following parameters have a NULL value: db_connect_string ORA-06512: at "SYSMAN.". EM_JOB_OPS', line 290 ORA-06512: at "SYSMAN.". GC_JOB', line 29 ORA-06512: at line 1

    Thank you

    Marcelo brands

    ESRI, technical director, OCP

    I solved the problem by following these steps.

    1 OEM12c > target > all targets > 'remove the motor pump target database '.

    2 OEM12c > target > all targets > systems > "to ensure that the target database system is also removed.

    3 OEM12c > Setup > manage Cloud control > Agents

    -Restart the agent database of the target container

    -It refreshes the C:\oracloud\agent_inst\sysman\emd\target.xml in the target database server where the agent is running

    4. in the server database, make a backup of the C:\oracloud\agent_inst\sysman\emd\target.xml file

    5 edit the file C:\oracloud\agent_inst\sysman\emd\target.xml

    -Remove all the entries that refer to the database of the target container

    -my case the xml file has several entries with different target system names pointing to the same target, weird container base, do not know how this could happen

    -J' removed all the and saved the xml file

    6, OEM12c > Setup > manage Cloud control > Agents

    -yet again, restart the agent database of the target container

    7 OEM12c > Add Target > manually add targets

    -Add the database to the target return container to oem12c

    8 OEM12c > target > databases

    -wait a few minutes for the target container of database state, to be 'green '.

    -Click on the database of the container link

    -Click availability > Backup & Recovery > scheduled backup...

    !!! It works fine now! I can create the backup job.

    Thank you

    Marcelo brands

    ESRI, technical director, OCP

Maybe you are looking for

  • How to change the URL of google?

    HelloCurrently I use Mozilla Firefox & Google Chrome for my navigation. But recently (4 days ago) it's URL has changed. Whenever I want to search anything through these two browser the URL appeared in 'Hong Kong' site. In search bar "https://www.goog

  • Use and standby battery Iphone6s time

    A few days ago, I got a replacement from apple (iPhone6s) phone and drains battery much faster compared to my previous iPhone6s. So I went to check the use of the battery and the day before, the usuage and Eve has the time (1 to 2 minutes of differen

  • No tile Internet TV Media Center

    I have a laptop for years and noticed that my Media Center had no Internet option that was supposed to automatically download TV.  Despite the disabling the firewall and tent several times a manual download, not Internet TV. I thought that maybe I ne

  • Deformed WebView Content

    1. use new app Wizard to create a new empty application2. replace the main.qml follows: import bb.cascades 1.0 create a page with a label{Page}{Of containerlayout: {DockLayout}ScrollView {}WebView {}{URL: 'https://accounts.google.com/o/oauth2/device/

  • Get items from DataModel w/o ListView (QML)

    I have a DataModel object that is not connected to the ListView. It is used to store data only, analyzed of JSON. How to generate a variable row (QList) in QML to get the first object in the list?