Clob datatype- very slow while appending

Hi,
please help on below pl/sql block.
I have written below code, but the response time is very slow.
the table - aux_comm_3_to_1 has more than 1 Lakh records.
and I have append all the record and send the record as clob OUT parameter to GUI.
Pls suggest me.
declare
TEMP_XML clob;
XML_OW clob;
begin
FOR rec IN (SELECT
FRAMEREFERENCEDATE,
EU_LEU_ID_OWNER,
EU_LEU_ID_SUBSIDIARY,
DIRECT_PERCENT,
QUALITY_IND_DIRECT_PERCENT,
SOURCE_DIRECT_PERCENT,
REF_DATE_DIRECT_PERCENT,
KIND_OF_CONTROL,
SOURCE_KIND_OF_CONTROL,
REF_DATE_KIND_OF_CONTROL,
DATE_OF_COMMENCEMENT,
SOURCE_DATE_OF_COMMENCEMENT,
REF_DATE_OF_COMMENCEMENT,
DATE_OF_CESSATION,
SOURCE_DATE_OF_CESSATION,
REF_DATE_OF_CESSATION,
SOURCE_TA_OWNERSHIP,
REF_DATE_TA_OWNERSHIP
FROM aux_comm_3_to_1 )
LOOP
TEMP_XML :=
'<TARGET_OWNERSHIP="'
|| idcounter
||'"FRAMEREFERENCEDATE="'||rec.FRAMEREFERENCEDATE
||'"EU_LEU_ID_OWNER="'||rec.EU_LEU_ID_OWNER
||'"EU_LEU_ID_SUBSIDIARY="'||rec.EU_LEU_ID_SUBSIDIARY
||'"DIRECT_PERCENT="'||rec.DIRECT_PERCENT
||'"QUALITY_IND_DIRECT_PERCENT="'||rec.QUALITY_IND_DIRECT_PERCENT
||'"SOURCE_DIRECT_PERCENT="'||rec.SOURCE_DIRECT_PERCENT
||'"REF_DATE_DIRECT_PERCENT="'||rec.REF_DATE_DIRECT_PERCENT
||'"KIND_OF_CONTROL="'||rec.KIND_OF_CONTROL
||'"SOURCE_KIND_OF_CONTROL="'||rec.SOURCE_KIND_OF_CONTROL
||'"REF_DATE_KIND_OF_CONTROL="'||rec.REF_DATE_KIND_OF_CONTROL
||'"DATE_OF_COMMENCEMENT="'||rec.DATE_OF_COMMENCEMENT
||'"SOURCE_DATE_OF_COMMENCEMENT="'||rec.SOURCE_DATE_OF_COMMENCEMENT
||'"REF_DATE_OF_COMMENCEMENT="'||rec.REF_DATE_OF_COMMENCEMENT
||'"DATE_OF_CESSATION="'||rec.DATE_OF_CESSATION
||'"SOURCE_DATE_OF_CESSATION="'||rec.SOURCE_DATE_OF_CESSATION
||'"REF_DATE_OF_CESSATION="'||rec.REF_DATE_OF_CESSATION
||'"SOURCE_TA_OWNERSHIP="'||rec.SOURCE_TA_OWNERSHIP
||'"REF_DATE_TA_OWNERSHIP="'||rec.REF_DATE_TA_OWNERSHIP
|| '"/>'
|| CHR (10);
XML_OW:=XML_OW||CHR(10)||TEMP_XML;
idcounter := idcounter + 1;
END LOOP;
end;
----------------------

Can you extend the test also with dbms_lob.writeappend? I am not on the same machine so so I am repeating all tests again (slightly modified):
SQL> set timing on
SQL> declare
   s   clob;
begin
   s := dbms_random.string ('X', 10000);
   for j in 1 .. 100 * 100 * 10
   loop
      s := s || 'x';
   end loop;
   dbms_output.put_line ('Length: ' || length (s));     
end;
Length: 104000
PL/SQL procedure successfully completed.
Elapsed: 00:00:20.49
SQL> declare
   s   clob;
begin
   s := dbms_random.string ('X', 10000);
   for j in 1 .. 100 * 100 * 10
   loop
      dbms_lob.append (s, 'x');
   end loop;
   dbms_output.put_line ('Length: ' || length (s));
end;
Length: 104000
PL/SQL procedure successfully completed.
Elapsed: 00:00:25.49
SQL> declare
   s        clob;
begin
   dbms_lob.createtemporary (s, true);
   s := dbms_random.string ('X', 10000);
   for j in 1 .. 100 * 100 * 10
   loop
       dbms_lob.writeappend (s, 1, 'x');
   end loop;
   dbms_output.put_line ('Length: ' || length (s));
   dbms_lob.freetemporary (s);     
end;
Length: 104000
PL/SQL procedure successfully completed.
Elapsed: 00:00:20.32So not much of a difference between first and third run ...

Similar Messages

  • My MacBook Pro gets very slow while doing  work like watching movies and using net .. video gets lag very often

    My MacBook Pro gets very slow while doing  work like watching movies and using net .. video gets lag very often and while surffing on net it gets very slow ...

    First, back up all data immediately, as your boot drive might be failing.
    There are a few other possible causes of generalized slow performance that you can rule out easily.
    Reset the System Management Controller.
    If you have many image or video files on the Desktop with preview icons, move them to another folder.
    If applicable, uncheck all boxes in the iCloud preference pane.
    Disconnect all non-essential wired peripherals and remove aftermarket expansion cards, if any.
    Check your keychains in Keychain Access for excessively duplicated items.
    Boot into Recovery mode, launch Disk Utility, and run Repair Disk.
    Otherwise, take the steps below when you notice the problem.
    Step 1
    Launch the Activity Monitor application in any of the following ways:
    ☞ Enter the first few letters of its name into a Spotlight search. Select it in the results (it should be at the top.)
    ☞ In the Finder, select Go ▹ Utilities from the menu bar, or press the key combination shift-command-U. The application is in the folder that opens.
    ☞ Open LaunchPad. Click Utilities, then Activity Monitor in the icon grid.
    Select the CPU tab of the Activity Monitor window.
    Select All Processes from the menu in the toolbar, if not already selected.
    Click the heading of the % CPU column in the process table to sort the entries by CPU usage. You may have to click it twice to get the highest value at the top. What is it, and what is the process? Also post the values for % User, % System, and % Idle at the bottom of the window.
    Select the System Memory tab. What values are shown in the bottom part of the window for Page outs and Swap used?
    Next, select the Disk Activity tab. Post the approximate values shown for Reads in/sec and Writes out/sec (not Reads in and Writes out.)
    Step 2
    If you have more than one user account, you must be logged in as an administrator to carry out this step.
    Launch the Console application in the same way you launched Activity Monitor. Make sure the title of the Console window is All Messages. If it isn't, select All Messages from the SYSTEM LOG QUERIES menu on the left. If you don't see that menu, select
    View ▹ Show Log List
    from the menu bar.
    Select the 50 or so most recent entries in the log. Copy them to the Clipboard (command-C). Paste into a reply to this message (command-V). You're looking for entries at the end of the log, not at the beginning.
    When posting a log extract, be selective. Don't post more than is requested.
    Please do not indiscriminately dump thousands of lines from the log into this discussion.
    Important: Some personal information, such as your name, may appear in the log. Anonymize before posting. That should be easy to do if your extract is not too long.

  • Keyboard is working very slow while on internet

    My laptop model is G 62 the keyboard is very slow while working in the internet

    Hi,              
    Firstly, it is not recommended to configure a DNS Server on the External Interface of the ISA Server.
    I suspect this issue may cause by some worm/virus infected computers from your internal network. Please run antivirus software on both ISA Server and internal clients.
    Besides, I recommend you to check in task manager or performance monitor to see if there are Heavy disk load and resource consumption, high CPU load, high memory usage and high network bandwidth consumption issues.
    You can also enable logging of traffic blocked by flood mitigation:
    In the console tree of ISA Server Management, click General. In the details pane, click Configure Flood Mitigation Settings. On the Flood Mitigation tab, select Log traffic blocked by flood mitigation settings.
    More information:         
    Overview of flood mitigation                        
    http://technet.microsoft.com/en-au/library/cc995196.aspx
    Best regards,
    Susie

  • Hi!I was restoring my MacBook pro to its factory setting by erasing the disk and reinstalling OS X lion via internet.but it is failing telling me that my network is very slow while I used the best network in the area.How sld I get an OS X lion to my CP?

    Hi!I was restoring my MacBook pro to its factory setting by erasing the disk and reinstalling OS X lion via internet.but it is failing telling me that my network is very slow while I used the best network in my area.How should I get an OS X lion to my CP? Is it possible to get it from another MacBook pro?Or is it possible to recover the erased OS X Lion without or with external disc?
    Thank you

    Hi OGELTHORPE!
    Thank you for your advice but I don't know where i can get it and where to get it. Also I don't know also how to use it.
    Could you please keep on helping me?
    Regards!

  • Form Opening is Very slow while opening from client PC

    We are running forms application in 10.1.2.0 application server. We have a peculiar issue of slowness while opening forms from client PC's and not while opening from application server itself.
    1) When opening the form from a Windows 7 PC it takes around 25 seconds
    2) When opening the form from a Windows XP PC it takes around 15 seconds
    3) When opening the form from the application server itself it took less than 3 seconds .
    In essence all forms when opened from application server are opening very fast and when opened from client PC's it takes undue time. What might be the reason for the same, can anyone help us and we are pondering over this issue for some time. What are the files of interest to be visited for these kind of issues. We enabled tracing level 5 in JRE and could not find any thing fishy over it.
    Request application server and forms experts to participate and help us to resolve.
    Thanks in advance.
    Edited by: ramarun on Sep 9, 2010 8:27 PM

    Hi ramarun,
    In etc/host file, enter hostname and IP Address entry in client machine...
    or try to access application via IP Address.
    I hope it will work for you...
    Regards,
    Ajinkya

  • I did software update for IOS 8 and my I phone 5s coming very slow while using the Internet please I need advise

    I did software update iOS 8 for my I phone 5s after That my phone coming very slow when i using internet

    Hi ..
    Reset the device:
    Press and hold the Sleep/Wake button and the Home button together for at least ten seconds, until the Apple logo appears.
    If that doesn't help, tap Settings > General > Reset > Reset All Settings
    If that doesn't help, tap Settings > General > Reset > Reset Network Settings
    You will have to re enter your Wi-Fi password.
    No data is lsot due to a reset.
    If nothing above has helped, try here >  iOS: Troubleshooting Wi-Fi networks and connections

  • Premiere Pro being very slow while previewing

    So recently my friend sent me a png sequence with a alpha channel. And what I want to do with it is put it in Adobe Premiere with my YouTube videos I will edit it with.
    But the problem was when I imported it as a png sequence in premiere and previewed the project, it stopped and started and acted very "laggy." I don't know why it is laggy because a png sequence is not a huge file.
    IF anyone can help me on how to preview it without lag that would be amazing   And is there such thing as a h.264 with an alpha channel?
    P.S: I did try converting the sequence into a QuickTime movie with a alpha channel. All it did was make it even more slow when previewing in premiere.

    Hi raffaele mariotti,
    Please mention some more information mentioned below.
    1. Have you taken any backup through time machine for your user profile?
    2. What are the media files that you are using in Premiere Pro CC 2014 ?
    Regards,
    Vinay

  • Mac OS very slow while TC is backing up

    I just want to know, is it normal for the Mac OS to be extremely slow, stop responding while TC and Time Machine are doing their initial backup?
    Message was edited by: danskinoff

    This is expected - there is a lot of hard drive activity taking place on the Mac while the initial backup is running. Best thing to do is let it run overnight when you are not using your Mac.

  • ITunes Response time is very slow while downloading.

    When iTunes is preforming some task it is not responsive on Windows 7.
    For example:  When it is downloading a program I click one of the libraries it can take up to 1 minute before that item is selected and the screen goes to that selection.  It appears that the file that is downloading has to complete before it process the command.
    It appears that everything that I click must wait for the download to complete before iTunes processes the click.
    Even if I am in another program like "Word" and click iTunes in the Taskbar it waits until the files gets downloaded before the iTunes app comes to the forefront.
    It does not matter if a device is plugged in or not. 
    Another sign is that progress bar (while downloading) goes to 0% to 100% with no (or maybe one or two) steps.
    Shouldn't download be a background task?

    I have the same issue.
    along with having to hold the power OFF for an inordinate amount of time to get the "thing" to shut down.
    AND, it's TOO QUIET. I have to get up and go look at the printer to see if it's doing anything at all.
    Ink cartridges are OUTRAGEOUSLY priced. Stupid Me. I neglected to see how much it would cost to operate this unit. IF I had checked, I would have bought a different printer (Epson). So now I'm stuck with a new out of ink printer after 2 days of use. Over $40USD to print 200 pages (IF I'm that lucky).
    There is NO setting to ignore color out notices to continue printing in B/W, so once one of the color segments runs out, the whole printer is useless.
    So now I have a scanner and still need a printer.

  • DDIC ACTIVATION very slow while applying SPS 7 to ECC 6.0

    Hello SDN
    I've been running this phase for at least 12 hours, is this normal ?
    How can I make it go faster?
    I have more patches to apply and I can't wait that long.
    Any help is appreciated.
    In my sm50 screen I see 2 background processes running :
    SAPLSTPA with status On Hold and
    RADMASDSC with status running and action sequential read of table DD03L
    When I see the detail of RADMASDSC I see that it is running.
    Thanks

    Hi,
    Since it is DDIC activation its not possible also to revert. I sincerely suggest you to overcome the problem without deleting the entry in the table. I haved faced the similar kind of issue in my experience and i resolved with the help of abaper. I suggest you to just get a help from abaper and creating the table field and flag the foreign key in the particular table. It will surely resolve your problem.
    Incase if you want to dlete the entry in database table level emans. Use this functional module
    Spam_reset _status in se37 and by forcefully you can delete the entry of the component. adn also please chck in table also pat01 pat02 and pat03..delete manually.
    Hope it will resolve ur problem
    Regadrs
    Vijay kumar G

  • Sequence run VERY slow with SeqEdit.exe

    Hi, My application sequence began to work very very slow while running under SeqEditor
    Looking in the Windows Task Manager, it shows 50% constantly!!
    Even steps like 'Lable' takes a longs time to execute.
    Under Operator Interface it works just fine.
    I have loaded some example sequence files from TestSTand/Example directory and they run just fine.
    It seems that the problem is only with this specific file.
    I can not use the SeqEditor as it is....PLEASE HELP!!!
    Thanks
    Rafi

    Sequence run fine with Operating Interface (as I pointed out in the first message).
    Attached is the sequence file.
    Thanks
    Rafi
    Attachments:
    AoC.seq ‏3391 KB

  • My pages app types very slow

    I've recently posted  this issue...my pages app is very slow while typing a document
    -I've no background apps in open.
    -the file was about 30 pages.
    -the text was typed in a table.
    -my pages version is 2.1
    -my icloud file sync is off in pages
    -The document is stored in my ipad and not on the network server
    And i have also tried re-starting the ipad but it was of no use.
    and please help me..it was very important..

    Try This...
    Close All Open Apps... Perform a Reset... Try again...
    Reset  ( No Data will be Lost )
    Press and Hold the Sleep/Wake Button and the Home Button at the Same Time...
    Wait for the Apple logo to Appear...
    Usually takes about 15 - 20 Seconds... ( But can take Longer...)
    Release the Buttons...

  • FireFox VERY slow with Norton Toolbar 4.6 on GMAIL and B of A, etc.

    Using XP Pro SP3 and FireFox 3.6.7, but has been slow for a while now. If I disable Norton ToolBar 4.6 (from NIS 2010) it is OK but IE 8 is fine. What happens is that GMAIL logs in and just hangs for a while. Even B of A or the Norton site. Even my ISP's site is VERY slow. A lot of forums are slow as well. Seems like sites that need a log-in have this issue.
    == URL of affected sites ==
    http://gmail.google.com

    I had done this and disabled ALL of the addons/plugins, and it was fine. As soon as I enabled the Norton toolbar, the problem was back. I then enabled everything except the Norton Toolbar and it was still good. I believe this is a Firefox issue as IE 8 works well with the Norton Toolbar enabled. I also see this when I go to my Netflix queue. Firefox is very slow while IE 8 shows the list quickly.

  • While creating Billing, system is very slow..performance issue

    Hi,
    While creating Billing, system is very slow. How can I debugg and provide the analysis where is the exact problem.
    This is showing performance issue.
    Waiting for kind response.
    Best Regards,
    Padhy
    Moderator Message : Duplicate post locked.
    Edited by: Vinod Kumar on May 12, 2011 10:59 AM

    hi,
    Chk the links
    http://help.sap.com/saphelp_nw04/helpdata/en/4a/e71f39488fee0ce10000000a114084/content.htm
    Re: How to create Secondary Index?
    How may secondary indices I can create on the ODS?
    Deletion of ODS index
    Ramesh

  • My performance is very slow when I run graphs. How do I increase the speed at which I can do other things while the data is being updated and displayed on the graphs?

    I am doing an an aquisition and displaying the data on graphs. When I run the program it is slow. I think because I have the number of scans to read associated with my scan rate. It takes the number of seconds I want to display on the chart times the scan rate and feeds that into the number of samples to read at a time from the AI read. The problem is that it stalls until the data points are aquired and displayed so I cannot click or change values on the front panel until the updates occur on the graph. What can I do to be able to help this?

    On Fri, 15 Aug 2003 11:55:03 -0500 (CDT), HAL wrote:
    >My performance is very slow when I run graphs. How do I increase the
    >speed at which I can do other things while the data is being updated
    >and displayed on the graphs?
    >
    >I am doing an an aquisition and displaying the data on graphs. When I
    >run the program it is slow. I think because I have the number of
    >scans to read associated with my scan rate. It takes the number of
    >seconds I want to display on the chart times the scan rate and feeds
    >that into the number of samples to read at a time from the AI read.
    >The problem is that it stalls until the data points are aquired and
    >displayed so I cannot click or change values on the front panel until
    >the updates occur on the graph. What can I do to be a
    ble to help
    >this?
    It may also be your graphics card. LabVIEW can max the CPU and you
    screen may not be refreshing very fast.
    --Ray
    "There are very few problems that cannot be solved by
    orders ending with 'or die.' " -Alistair J.R Young

Maybe you are looking for

  • Sub-Contraction challen creation.

    Hi , While creating sub-contracting challen . i am geeting below error. Please specify the number of line items for the challans. Message no. 8I802 Please Guide me SAM

  • External HDD StorE PA4096-1HF4 not detected in Windows 7

    External HDD Model: PA4096-1HF4 Type: StorE Art 640 GB, 3.5 inch, USB 2.0 OS: Windows 7 Home Premium The drive is not showing up in explorer (computer) or device manager or disk management. Only _*suggestion*_ I have found so far is to uninstall USB

  • OIM Read only Admin Role

    Hello Everyone Is there something like read-only OIM Admin role?. My manager wants to just see everything done by a system administrator or xelsysadmin . He doesn't want to modify any date, but he just wants to access everything added by the administ

  • How to get file name of the form attachment?

    Hi, is there anybody who is able to help me with the following problem??? I started my process from Workspace ES and as a first step I attached one locale file (IMG.JPG or IMG.TIF e.g.) as a form attachment. I used "Attachments" bookmark in the Works

  • Need to track Budget at WBS wrt Value & Qty both

    Dear All PS Gurus, We have specific requirement to track Budget in PS ( WBS Level ) thru material qty as well as value. Are there any work arounds or any other solutions.. Umesh Bagul