ORA-03123 during the use of formulas of UTL_FILE package in oracle 10g

Hi all
I have created a 'REPORTS' as 'E:\EXCEL_TESTING_FORM\' directory and to grant read, write to this directory at scott.
and also a given grant execute on UTL_FILE to scott;

I wrote this code in a trigger pressed the button and my file name is the file somename.xls

After printing the first line as 7369SMITH3000 in a single cell when it goes to print the second employee record is to show
ORA-03123 inside the loop.

CURSOR EMP_DATA IS
SELECT * FROM SCOTT. EMP;

C_REF EMP_DATA % ROWTYPE;
L_FILE UTL_FILE. TYPE_DE_FICHIER;
V_PATH VARCHAR2 (200): = ";

BEGIN

V_PATH: = "REPORTS";
L_FILE: = UTL_FILE. FOPEN (V_PATH, P_FILE_NAME, 'W');

EMP_DATA OPEN;

LOOP
EXTRACT THE EMP_DATA IN C_REF;
WHEN THE OUTPUT EMP_DATA % NOTFOUND;

UTL_FILE. PUT_LINE (L_FILE, TO_CHAR (C_REF. EMPNO));
UTL_FILE. PUT_LINE (L_FILE, C_REF. ENAME);
UTL_FILE. PUT_LINE (L_FILE, TO_CHAR (C_REF. SAL));

END LOOP;
CLOSE EMP_DATA;

UTL_FILE. FFLUSH (L_FILE);
UTL_FILE. FCLOSE (L_FILE);

Please guide me how to avoid this error and also how to print cell wise why because it's printed in a single cell.

Please answer...

What is a network drive? If so, try if the same code is running on a local directory, maybe the network drive is smehow is not accessible.

Tags: Oracle Development

Similar Questions

  • What is the main reason for the use of SERIALLY_REUSABLE in your package?

    Hi Experts,

    What is the main reason for the use of SERIALLY_REUSABLE in your package?

    At first glance, the most popular reason seems that some developers forget to close cursors. Therefore, it is a good way to close automatically when your code is stopped during the same session.

    Second, if your business rules require that package variables still need to put the SERIALLY_REUSABLE default values is good for this.

    So, what's your reason?

    Thanks in advance.

    From http://docs.oracle.com/database/121/LNPLS/packages.htm#LNPLS99924:

    After the unit of work (call Server) a SERIALLY_REUSABLE complete package, Oracle database performs the following operations:

    • Closes all open cursors.
    • No free memory (for example, memory for collection and long VARCHAR2 variables)
    • Returns the instantiation of the package to the collection of reusable instantiations kept for this package.

    Explicit cursors in SERIALLY_REUSABLE packages:

    http://docs.Oracle.com/database/121/LNPLS/packages.htm#LNPLS99923

    I would not support using SERIALLY_REUSABLE instead of programming and the cursor's lifecycle management practices.

    > What is the main reason for the use of SERIALLY_REUSABLE in your package?

    If your package uses large amounts of memory in the State, especially in a multiuser environment heavy wherever the memory usage adds up and memory will not clean until the session is closed and the State is not held beyond the call to the package, then there's your use case.

  • ORA-01422: during the update supporting objects

    I'm looking to replace/upgrade an application, for example, I have a new version of the application to replace the existing one.

    Importation and application installation ran without error, but when I run the upgrade to support objects I'm repeated "ORA-01422: exact fetch returns more than number of lines '-the browser page is updated constantly with the same message and I have to kill the browser session to regain control.

    I don't see the upgrade scripts that cause this issue and even if there were, I would have expected the error appear once only?

    Any ideas as to what I can do to debug this situation?

    Source APEX: 4.1.1 Oracle 11g

    Destination APEX: 4.2.4, Oracle 10g

    --
    Andy

    The question was threefold:

    1. in my script upgrade that I have created a function that could, it is averred, ORA-01422 result.

    2. the service has been used as a condition (PL/SQL expression) on a later script

    3. after hitting the exception during the upgrade, it seems that APEX upgrade process in a loop - (the page refreshed continuously with the same error message).

    MetaLink support was desperately poor, I just solved the problem by placing an APEX_DEBUG. ACTIVATE as a precursor script in the upgrade and then trawling through the paintings of debugging apex.

    NB. Steps 1 and 2 can be reproduced by creating a function non-compilation and mentioning that:-the repeated message will refer to the compile error.

  • ORA-1450 during the installation of the repository

    I tried to use the MISP utility on a 10.2.0.4.4 database on Red Hat Enterprise Linux Server release 5.7 (Tikanga) 2.6.18 274.7.1.el5 (64-bit). I got the below error when you try to create the repository. Anyone else has come across this or have no work around for it? The plan is to update this database to 11.2.0.3 on new hardware. It will go to AL32UTF8 WE8ISO8859P1 in the process.
    Thank you
    Brian


    29.13:56:32:529; P035; S; 10042 encountered an error during the installation of the repository: error occurred during batch processing: ORA-01450: maximum (3118) key length exceeded

    29.13:56:32:531; P035; S; 10008 cannot install the repository.
    29.13:56:33:211; P035; I; 10016 uninstalled repository.

    The MISP repository requires a tablespace with block size of 8 k or higher. Please, try the following for MISP 1.1:

    (1) create a tablespace with block size 8 k
    (2) change the default tablespace for the user of the SYSTEM to use this new space of tables
    (3) install the MISP repository on a new basis
    4) reset the user of the SYSTEM to use the original table space

  • RMAN-04014: failed to start: ORA-00600 during the duplicate database

    Hello

    Oracle version: 11.2.0.2

    OS: linux rhel 5

    I do duplicate database of active database
    rman target sys/*******@pindb AUXILIARY sys/*****@test
    
    Recovery Manager: Release 11.2.0.2.0 - Production on Mon Nov 26 19:56:41 2012
    
    Copyright (c) 1982, 2009, Oracle and/or its affiliates.  All rights reserved.
    
    connected to target database: pindb (DBID=4116200880)
    connected to auxiliary database: TEST (not mounted)
    
    RMAN> run {
    allocate channel C1 type disk;
    allocate auxiliary channel DUP type disk;
    DUPLICATE TARGET DATABASE  TO 'TEST' FROM ACTIVE DATABASE  DB_FILE_NAME_CONVERT '/oradata/pindb','/oradata/test';
    }2> 3> 4> 5>
    
    using target database control file instead of recovery catalog
    allocated channel: C1
    channel C1: SID=699 device type=DISK
    
    allocated channel: DUP
    channel DUP: SID=5 device type=DISK
    
    Starting Duplicate Db at 26-NOV-12
    
    contents of Memory Script:
    {
       sql clone "create spfile from memory";
    }
    executing Memory Script
    
    sql statement: create spfile from memory
    
    contents of Memory Script:
    {
       shutdown clone immediate;
       startup clone nomount;
    }
    executing Memory Script
    
    Oracle instance shut down
    
    connected to auxiliary database (not started)
    released channel: C1
    RMAN-00571: ===========================================================
    RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
    RMAN-00571: ===========================================================
    RMAN-03002: failure of Duplicate Db command at 11/26/2012 19:57:07
    RMAN-06403: could not obtain a fully authorized session
    RMAN-04006: error from auxiliary database: ORA-01034: ORACLE not available
    ORA-27101: shared memory realm does not exist
    Linux-x86_64 Error: 2: No such file or directory
    RMAN-03015: error occurred in stored script Memory Script
    RMAN-04014: startup failed: ORA-00600: internal error code, arguments: [kck_rls_check must use (11,0,0,0,0) or lower], [kdt.c], [9576], [11.2.0.2.0], [], [], [], [], [], [], [], []
    RMAN-04017: startup error description: ORA-32004: obsolete or deprecated parameter(s) specified for RDBMS instance
    Please can someone offer

    Thank you

    Hello;

    In my view, that it is a bug that has to do with the compatibility of the compression.

    I think that work around is:

    alter system  set "_compression_compatibility"="11.2.0";
    

    Let me confirm with a document number of MOS

    Subsequently Cannot find the doc of MOS - this has some details:

    http://www.acehints.com/2011/11/fix-RMAN-duplicate-database-failed-ora.html

    http://bryangrenn.blogspot.com/2011/12/ora-600-kckrlscheck-must-use-110000-or.html

    Best regards

    mseberg

    Published by: mseberg on November 26, 2012 16:07

  • Error occurs during the use of Toshiba SD on Portege start utility

    When im trying to use the utility as a tutorial has shown on this Web site to get the SD card to start the toshiba restore DVD, I get the error:

    "Error reading. This disc may be unformatted or not introduced. "

    When I go to my computer and open the sd card, I get the error the disc needs formatting I'll do next.
    The sd card works fine after for other files that I put on.

    When I return to the utility boot sd I get the same error, and in my computer, I get the same error to format the drive.

    If the utility is to mess up something.

    I have UN and then re installed but still the same.

    Initialization of the sd is my last chance to restore my computer which is on the brink of death.

    Hello

    What files did you put on the SD card?
    As much as I know about the usefulness of boor SD card installs a file on the SD card as on the bootable floppy drive.

    Did you place the files from the recovery on the SD CSA CD?
    If Yes, then I n t think you will be able to recover the laptop that way.
    You must use the recovery CD to recover the laptop.

    If you have no external CD/DVD drive bootable and you won't buy such device, so I recommend you to visit a Department or an ASP and there to recover the operating system.

  • It is mandatory to use the manufacturers during the use of the collections?

    Code

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

    DECLARE

    Int_varray TYPE is VARRAY (3) integer;

    VARRAY_INT INT_VARRAY: = int_VARRAY();

    BEGIN

    DBMS_OUTPUT. Put_line ('VARRAY initialized with null');

    VARRAY_INT: = int_VARRAY (NULL, NULL, NULL);

    I'm in 1.3

    loop

    DBMS_OUTPUT. PUT_LINE ('INT_VARRAY('|| i||'): ' |) VARRAY_INT (i));

    end loop;

    DBMS_OUTPUT. Put_line ('VARRAY initialized as VALUES');

    VARRAY_INT: = int_VARRAY (11,12,13);

    I'm in 1.3

    loop

    DBMS_OUTPUT. PUT_LINE ('INT_VARRAY('|| i||'): ' |) VARRAY_INT (i));

    end loop;

    end;

    OUTPUT

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

    VARRAY initialized with null

    INT_VARRAY (1):

    INT_VARRAY (2):

    INT_VARRAY (3):

    VARRAY initialized as VALUES

    INT_VARRAY (1): 11

    INT_VARRAY (2): 12

    INT_VARRAY (3): 13

    The sample code above for collections works perfectly well with the help of a constructor method. However, my question is that is it possible to re - write the same code without using Builder methods?

    or is it mandatory to use constructors when the use of the collections?

    But he has not yet answered my question. Is it mandatory to use a constructor method? If 'NO', then how we can treat a VARRAY (not the tables / associative PLSQL) without a constructor method?

    When you have a basic question about the functionality of the Oracle, you should ALWAYS read the documentation.

    The doc of the PL/SQL language answers your question

    With the help of documents and Collections of PL/SQL

    Initializing and referencing Collections

    Until you initialize it, a nested table or varray is atomically null; the collection itself is zero, not its elements. To initialize a nested table or varray, you use a builder, a function defined by the system with the same name as the collection type. This function constructs collections from the elements that is passed.

    You must explicitly call a constructor for each varray and nested table variable. Associative arrays, the third type of collection, use no constructors. The constructor calls are allowed everywhere where function calls are allowed.

    Example 5-10 Initializes a nested table using a constructor, which resembles a function with the same name as the collection type.

  • Error ORA-022887 during the insert operation how to handle correctly...

    Hello everyone I got an error in during the insert operation how to handle correctly?
    SQL statements below.

    INSERT STAFF. TRANSLATIONS (TID, SCRIPT_NAME, TAG, TR, FR, LOCAL)
    VALUES ((SELECT LOCATION. SQX_TID. (NEXTVAL DOUBLE AS TID), 'TEST_TEST', 'TEST', 'TR', 'FR', 'LOCAL');

    Thank you

    Try this,

    INSERT STAFF. TRANSLATIONS (TID, SCRIPT_NAME, TAG, TR, FR, LOCAL)
    VALUES (PERSONAL. SQX_TID. NEXTVAL, 'TEST_TEST', 'TEST', 'TR', 'FR', 'LOCAL');

  • Limitations on the use of SQL/PLSQL functions in reports 6i / 10g

    Hi gurus...

    We have a limitation on the use of TRIM, Regular Expressions, CASE operator subquery in cursor in reports 6i/10 g...
    Could you please let us know all these limitations for reports 6i / 10g. Any reference document will be much more useful...

    Any help will be greatly appreciated...
    Thank you in advance...

    gt1982

    There is no documentation. For example, documentation reports 6i can't say you cannot use regular expressions, simply because it is right, it did not exist at the time.
    The pl/sql in the forms and reports engine is always behind, on the database. You should put as much code as possible in the procedures of database and the views if you want to use again (pl /) sql features.

  • Satellite L630-15U - block during the use of the

    I have a L630-15U Windows 7 Professional 64 bit, when I use in battery mode after a few minutes it crashes often. Everything has been frozen, I need to turn it off.

    Hey Buddy,

    What do you think average either it blocks during use?
    This means after a few minutes when you use your laptop with battery only if freezes and has to be restarted, no?

    Well, it's not easy to say which is the reason. You use the original Toshiba battery? Otherwise I recommend the spare parts and test with an original Toshiba battery.

    Also, you could try a BIOS update. Charge the battery up to full East, leave AC connected adapter and start updating the BIOS as an administrator. Close all programs that are running before do you (also antivirus).

    Check this box!

  • Why my iTunes library sound randomly cut during the use of my new macbook pro and the old Bose speakers?

    Why my iTunes library sound randomly cut during playback on my new Macbook Pro and the old Bose speakers?

    The speakers connect through a USB port, instead of by means of the mini plug stereo audio output (headphone)?

    If it uses the standard audio out Jack, try to plug ordinary headphones instead.  The problem goes away or still occur?

  • Bug found during the use of references to the control in subVis on Compact RIO?

    Hallo,

    I have a simple task. I want to read higher VI into a Subvi the real value of a control to a level. I want to solve this problem by using a reference to the control.

    I have attached a simplified program that shows this.

    But the problem is now. When I run the main VI on a cRIO-device, the indicator "DataByReference" is not updated with the actual value. Only when I opened during execution of the "RefMain.vi" too, then everything works fine.

    More strange thing is, when I run the VI of hand on the host PC, everything works well, also without having to open the "RefMain.vi" when executing.

    Someone at - it an explanation for this behavior?

    Thanks in advance!

    Bernd

    This isn't a bug.  See this explanation.

  • Help! ORA-12703 without the use of convert

    Hello!

    First of all. I m not crazy. I swear.
    It s a very strange error.

    I have a form.
    This form has a trigger that calls a function inside a package [form_var: = my_pkg.my_func (x);]
    It's summer for the years of work.

    I've added another feature in this package.
    This new feature is not served in my forms. Not at all. No other function inside the package calls the new function.
    It s a new isolated function. No object, he still uses. I'll use the latter, but nothing is use it to know. Claire?

    But now when I run my form, I get the error ORA-12703 when calling my_pkg.my_func (the older function).
    (new: my_func does not call the new function).

    If I comment the new function of package specifications (no need to comment in the package body), it works again.
    If I run outside the shape (sqlplus) it works (the old function and the new function: two works).
    Nowhere in my code there are conversion or anything that may require a translation of charset.
    There was no change in the server. Or in the client and the form designer. Or in windows.

    Does anyone know why a unused function causes this error?

    Forms [32-bit] versão 6.0.8.11.3 (being Produção)
    Oracle Database 10g Release 10.2.0.3.0 - 64 bit Production

    Forms 6.0.8.11.3 is not supported for database 10.2.0.3.0. So, if I were you, I would upgrade first to a later version of forms (6.0.8.26, fixes 17 game I think).

  • ORA-01427 during the attempt to INSERT SQL job

    Hello

    I have non-logiques problem.

    I use Oracle 10 g.
    I have a query that contains some subqueries, this is pretty normal query as similar milion:

    SELECT a.field1,
    (SELECT b.field2 FROM tab2 b WHERE b.key = a.key) Field2
    OF tab1 a

    Query works fine, amount of the returns expected Recordset, but while I'm saving it somehow it returns me an error:
    ORA - 01427:single - line subquery returns multiple rows

    It would be normal that I have by running a SELECT statement. But SOME major work - error occurs when I try to save the results somehow - INSERT, CREATE TABLE AS or save it to file.

    Help, please.
    Thank you.

    nodeX wrote:

    Query works fine, amount of the returns expected Recordset, but while I'm saving it somehow it returns me an error:
    ORA - 01427:single - line subquery returns multiple rows

    No it's not. Most likely you use SQL * Developer, Toad, SQL * Navigator or another GUI tool that retrieves the screen by screen lines. So when you run this select your tool retrieves and displays just the first screen and it happens so that for the first lines of the scalar subquery in your select screen returns just one line. However, when you issue INSERT SELECT all lines are read, and at least one of them, results in a scalar subquery returns more than one line. Do a complete test of your question, SELECT, SELECT your tool try and extract all lines (in most of the tools it's > button) or post your query in SQL * more. In all cases:

    SELECT a.field1,
    (SELECT b.field2 FROM tab2 b WHERE b.key = a.key) field2
    FROM tab1 a
    

    means the key of the column in the table tab2 is logically unique for any value of tab1.key.

    SY.

  • Why get ORA-00942 during the validation of PL/SQL cursor

    The database is 10 gr 2.

    ST_PKG_UTILITIES contains a procedure called "p_insert_update_person_info".

    The procedure includes a cursor that selects a view 'CDS_CIS_ETHNICITY '.

    I am logged in as the owner of the schema of the package. The view lies in another schema, but I have the right to SELECT on the view.

    When I try to compile the package, I get "ORA-00942: table or view does not exist", pointing to the CDS_CIS_ETHNICITY view.

    However, if I SELECT directly from the view using a SQL window, it returns information without problem.

    Code view is a SELECT statement on a table across a db_link. However, given that I can select directly from the view, I am not clear why I would get the error because the view is selected, within PL/SQL.

    Note that the table was originally, on the same server that the schema that I am now, so no db_link was necessary. When the schema of the table has been moved to a new server, we added the db_link. However, the package was never changed, we were careful to reproduce the names of objects that are used by the package, when building the db_link.

    Ideas on this issue would be appreciated.

    Thank you
    VP

    Published by: user618800 on December 9, 2008 14:53

    Hello

    Grant privileges directly to the owner of the whole.

    Looks like the privileges that you have about this point of view have been granted to a role, and the owner of the package has this role.
    Roles do not count inside stored procedures. You must have privileges granted directly to the owner (or to the PUBLIC, which probably does not apply in this case).

Maybe you are looking for

  • do not open program

    I have a studio 1555 sound running windows 7 64 bit and I have updated all drivers MI (new bios and stuff recommended dells are) tryin to play wow... I click on the launcher and the small mini screen appears fine, I press play then it goes all black

  • Failed to read the serial number or of SNIDS on label Aspire 5100.

    Hello I use the search function but did not find a question quite like this - little surprising? A family member gave me a laptop Aspire 5100 that no power, fear of the system board.  Not seem to receive a wave of newer computers with bad cards syste

  • Dot net Frame work 2.0 SP2 and 3.5 Sp1 failed with error 0 x 80070643

    Can you please help me out with the solution for Dot net Frame work 2.0 SP2 and 3.5 Sp1 failures that occur frequently. We tried with the dotnet uninstall and update with the last, but still the questions are on the same machine when we have updated

  • A startup with a USB key T410

    I have a PowerEdge T410 Server I bought in July 2009.  I want to change the operating system of SBS 2008 to Windows Server R2 2012.  Because the iso file for the new operating system is about 5.1 GB, I will not be able to use a DVD to install the new

  • style and do not arise when exporting images

    So I'm building a "Web site" / interactive portfolio. It's for an iPad but I won't internet during the event so there all be locally stored or is there a program that will open without an internet connection? Because what im doing now is downloading