Job created successfully but actually failed

Dears,
I created this job by HR user to refresh the Materialized View automatically every 15 minutes as below:
BEGIN
DBMS_SCHEDULER.CREATE_JOB(
JOB_NAME => 'Job1',
JOB_TYPE => 'PLSQL_BLOCK',
JOB_ACTION => 'EXEC DBMS_MVIEW.REFRESH(''MV_employess'',''C'')',
START_DATE => SYSTIMESTAMP,
repeat_interval => 'freq=MINUTELY;interval=15',
END_DATE => NULL,
ENABLED => TRUE,
AUTO_DROP => FALSE,
COMMENTS => 'Refreshes Materialized View');
END;
/PL/SQL procedure successfully completed.
The job created successfully but while querying the "DBA_SCHEDULER_JOBS" found that failure_count is 1. It means that job created successfully but actually failed.
can you please help me ?
Many thanks & regards,

USER_SCHEDULER_JOB_RUN_DETAILS was very useful as i found some errors like ORA-06550 & PLS-00103 errors.
i solved the issue and job has been run successfully.
Many thanks for support

Similar Messages

  • Error workflow has been created successfully, but failed to publish and will not be listed in the Project Center

    hello,
    when i try creating projects in Project center am posted on with this error.
    Your new XXXX workflow has been created successfully, but
    failed to publish and will not be listed in the Project Center.For more information on the failure, visit the My Queue Jobs page or contact your administrator.
    Any help would be appreciated!!!!!
    Thanks regards, Vignesh.

    hello Rouyre,
    Thanks for ur reply
    Am using 
    Microsoft Project Server 2013
    15.0.4420.1017
    Yes! It is Custom EPT with Custom Workflow(Declarative Workflow) built through VS2012
    after associating the Site workflow with EPT i try creating Projects using my Custom EPT since then am posted on with this error.
    ULS Error:Log
    07/04/2014 10:21:38.03 Microsoft.Office.Project.Server (0x1840)
    0x06B8 Project Server                
    Queue                        
    ad3fy Critical
    Standard Information:PSI Entry Point: <unknown>  Project User: <unknown>  Correlation Id: <unknown>  PWA Site URL:   SA Name: <unknown>  PSError: <unknown> A queue job has failed. This is a general
    error logged by the Project Server Queue everytime a job fails - for effective troubleshooting use this error message with other more specific error messages (if any), the Operations guide (which documents more details about queued jobs) and the trace log
    (which could provide more detailed context). More information about the failed job follows. GUID of the failed job: 39cd36d6-3603-e411-b33e-00155d00091f. Name of the computer that processed this job: 3eebbc1d-7558-4050-bf5d-d985b23b89f5 (to debug further,
    you need to look at the trace log from this computer). Failed job type: ReportWorkflowProj...
    2c1ea19c-5849-002d-b89f-50aaf0a752fd
    07/04/2014 10:21:38.03* Microsoft.Office.Project.Server (0x1840)
    0x06B8 Project Server                
    Queue                        
    ad3fy Critical
    ...ectDataSync. Failed sub-job type: ReportWorkflowProjectDataSyncMessage. Failed sub-job ID: 1. Stage where sub-job failed:  (this is useful when one sub-job has more than one logical processing stages).
    2c1ea19c-5849-002d-b89f-50aaf0a752fd
    07/04/2014 10:21:38.03 Microsoft.Office.Project.Server (0x1840)
    0x06B8 Project Server                
    Queue Jobs                    
    ad3fy Medium  
    Error is: GeneralQueueJobFailed. Details: Queue Attributes:  39cd36d6-3603-e411-b33e-00155d00091f  3eebbc1d-7558-4050-bf5d-d985b23b89f5  ReportWorkflowProjectDataSync  ReportWorkflowProjectDataSyncMessage  1    2c1ea19c-5849-002d-b89f-50aaf0a752fd
     . Standard Information: , LogLevelManager Warning-ulsID:0x000DD158 has no entities explicitly specified.
    2c1ea19c-5849-002d-b89f-50aaf0a752fd
    07/04/2014 10:21:38.03 Microsoft.Office.Project.Server (0x1840)
    0x06B8 Project Server                
    Project Server Database      
    ah91z Medium  
    Successfully got the connection string (database name=[ProjectWebApp_Practice], id=1f6004ae-5d8a-41d2-81f9-e424a31484aa, type=Consolidated). Requested access level=ReadWrite: Data Source=XXXX;Initial Catalog=ProjectWebApp_Practice;Integrated Security=True;Enlist=False;Pooling=True;Min
    Pool Size=0;Max Pool Size=100;Connect Timeout=15
    2c1ea19c-5849-002d-b89f-50aaf0a752fd
    07/04/2014 10:21:38.04 Microsoft.Office.Project.Server (0x1840)
    0x06B8 Project Server                
    Queue Jobs                    
    ad3fz Medium  
    PWA:http://XXXX:10000/PWAPactice, ServiceApp:Project Server Service Application, User:PROJECTSERVER\system, PSI: [QUEUE] receiver http://XXXX:10000/PWAPactice: Group 3bcd36d6-3603-e411-b33e-00155d00091f type = ReportWorkflowProjectDataSync aborted at
    Message 1, LogLevelManager Warning-ulsID:0x000DD159 has no entities explicitly specified.
    2c1ea19c-5849-002d-b89f-50aaf0a752fd
    07/04/2014 10:21:38.04 Microsoft.Office.Project.Server (0x1840)
    0x06B8 Project Server                
    Queue Jobs                    
    ad3f2 Medium  
    PWA:http://XXXX:10000/PWAPactice, ServiceApp:Project Server Service Application, User:PROJECTSERVER\system, PSI: [QUEUE] receiver http://XXXX:10000/PWAPactice: Group 3bcd36d6-3603-e411-b33e-00155d00091f correlation 82705dc5-3603-e411-b33e-00155d00091f
    type = ReportWorkflowProjectDataSync failed at Message 1 Errors: GeneralQueueJobFailed, LogLevelManager Warning-ulsID:0x000DD15C has no entities explicitly specified.
    2c1ea19c-5849-002d-b89f-50aaf0a752fd
    Thanks regards, Vignesh.

  • How to create a Pooled VDI infrastructure using Win server 2012 as VM image?I have followed the "usual" way to build a pooled VDI desktop using Win7 or Win8 with success, but it fails when I use an image of Win Server 2012 as VM

    I have followed the "usual" way to build a pooled VDI desktop using Win7 or Win8 with success, but it fails when I use an image of Win Server 2012 as VM instead.
    Am I overlooking something?  Should I need to prepare the image in a different way? (Sysprep differently?)
    Thanks

    Hi,
    Thank you for your posting in Windows Server Forum.
    Can you specify the error which you are facing during VDI setup for server 2012?
    I might think that you need to check the memory setting for server 2012, as might happens that due to less memory you can’t setup the VDI setup properly. 
    Memory: If the Master VM is configured with static memory, it must have at least 1024 MB as startup RAM. If the Master VM is configured with dynamic memory, the maximum RAM must be at least 1024 MB.
    Please check beneath article for information.
    Windows
    Server 2012 2,500-user pooled VDI deployment guide (Doc)
    Single Image Management for Virtual Desktop Collections in Windows Server 2012
    Hope it helps!
    Thanks.
    Dharmesh Solanki

  • Problem in Background Job. Job Completed Successfully but data not Posted

    Hi All,
    There is a problem in Background Job in Production server (600).
    The job completed successfully but data not posted.
    The same Job was working perfectly till the starting of the May month.
    but now it is not working and rebate has not been posted.
    Where to check and what to check
    Pls suggest.
    Regards,
    P Kamal

    Hi ,
    Please first check the status of the Job , ifs successfully completed then debug it (tcode JDBG) and 
    check out,  whether the values passed (might be using Import-export ,set-get parameter Ids) to the Job are getting passed properly or not. These values might not be getting passed properly.
    If it has some error in Job Log then let me know the error.
    Regards,
    Uma

  • Job finished successfully but Spool not generated(no spool icon)

    I am generating a report which . When the program in scheduled, the job completed successfully but spool icon is not available. Could any one suggest us the reason why spool has not generated. Thanks in advance!

    Hi,
    When executing report, Spool gets generated only when an Output is generated. Please check if output exits for the selection criteria.
    Also check any special mechanisms are used that diverse the ouput when executed in background.

  • With installation of 10.1 I lost finder search function. The finder window appears, but no matter what I put in the search window, nothing is found. I re-installed it with initial success, but it failed again very soon.

    With installation of 10.1 I lost finder search function. The finder window appears, but no matter what I put in the search window, nothing is found. I re-installed it with initial success, but it failed again very soon.
    MacBook Pro (15-inch, Mid 2010)
    OS X 10.10.1

    Hey Reoh, 
    Thank you for contributing to the Apple Support Communities. 
    If searching for files in Finder doesn't return any results, try using the steps in this article to reindex the Spotlight search index of your MacBook Pro hard drive:
    Spotlight: How to re-index folders or volumes - Apple Support
    Sincerely,
    Jeremy

  • A new top level site was created successfully but won't launch. What can be the cause for this?

    A site collection was created with the URL intranet.contoso and it was added to the DNS as intranet.contoso. The top-level site was created successfully after that with the URL being
    http://intranet.contoso/main but it is not launching and the following is the error message -
    This page can't be displayed.
    This will be a production environment so disabling the security loopback will not be an option. Any suggestions?
    Many Thanks,

    I can connect only to the SharePoint Central Administrator from the client computer but not the top level site.
    The error i'm getting is This page can't be displayed.
    Make sure the web address http://contonsoportalis correct
    Look for the page with your search engine
    Refresh in a few minutes
    Fix connection problems - When clicked the following shows up "Make sure the computer or device is turned on and connected to the network" Windows can't find contosoportal. If the computer or device you are trying to reach is nearby,
    make sure it is turned on and connected to the network. Otherwise contact your network administrator for assistance.
    The DSN already had a host created for an intranet that is running SharePoint 2010 called intranet so I created a new host (A and AAA) named it Portal insert the ip address of the new sharepoint 2013 server but it still didn't work.
    This is the configuration shown in the DNS
    Host A Tab -
    Host (uses parent domain if left blank)
       Portal.contoso.local
    IP address: 192. X.X.X for the SharePoint Server
    ( Should I create a CNAME instead of a new host for the portal? )
    I added the host names in the register but it still does not work....
    It's a virtual environment running on top of hyper V - One server for SharePoint another for SQL and both joined to the DC.

  • Exp job completed successfully but nothing happend

    Hi,
    I am using oracle 8.1.7 with enterprise manager on windoews 2000 server.
    Exp job is not working. Job completed successfully without any error but The log only shows the help message of exp command. Simmilarly if i use exp command on prompt then it also returns the help message.
    However imp is working fine.
    Anybody can help please.

    Hi ,
    Please first check the status of the Job , ifs successfully completed then debug it (tcode JDBG) and 
    check out,  whether the values passed (might be using Import-export ,set-get parameter Ids) to the Job are getting passed properly or not. These values might not be getting passed properly.
    If it has some error in Job Log then let me know the error.
    Regards,
    Uma

  • Backup appears to succeed but actually fails

    We're trying to configure backups of our Hyper-V VMs that are hosted on an SMB 3.0 clustered scale out file server and we've run into a wall. DPM works for backing up SQL and Exchange with minimal problem, but it seems to silently fail when trying to back
    up Hyper-V VMs.
    When setting up a VM to back up, it appears as expected under the Hyper-V cluster's name and expands to show "HyperV" and then expands again to show "Offline\VMName" - the VM is turned off, so I believe this is as expected. We then continue
    the setup using all default settings for the backup.
    Once it is done setting up, DPM shows that the protection group is "OK" on the Protection tab and the server itself shows "OK" with the green checkmark.
    Trouble starts if you look at the details for the VM. It is showing only 99.8 MB used (the VHD alone is over 30 GB on that particular VM). Further, if you go to the Recovery tab, the VM doesn't show up there at all.
    If I then attempt to run a consistency check or create a recovery point, it fails saying it is in an inconsistent state. Running the consistency check again, so not fix the inconsistency.
    The only logging I can see is an Event 33223 on the DPM server saying the "Backup job for datasource: Offline\VMName on production server: SCVMM VMName Resources.cluster.domain.com failed." I can't
    find anything in the logs on the Hyper-V host that the VM is on nor can I find anything logged on the SOFS cluster that hosts the VM VHDX files.
    How can I track down the source of this problem? There is nothing in the logs or in the errors in DPM pointing to the root issue.

    Well, I'm apparently just blind.
    Was pretty sure this was DPM 2012 R2. It in fact was not.

  • AIX mount_cmd of brbackup is successful but assumed failed

    Dear All,
    I am configuring oracle backup and script for mounting tape in tape_box without Tivoli. The script (/usr/sap/P01/SYS/exe/run/mount_tape.csh) is empty (for testing) or only contain "exit 0", but brbackup always recognized this as failed. The tape box is /dev/smc0 and the drive is /dev/rmt1. Below is the excerpt of error log and profile. I have already tested the profile using tape only, without tape_box, smc0, and without mount_cmd successfully. Can you see what seems i missed here? Thank you.
    Regards,
    -asp-
    BR0259I Program execution will be continued...
    BR0207I Volume in device: /dev/rmt1.1 will be initialized with name: P01B01
    BR0280I BRBACKUP time stamp: 2008-10-24 17.14.38
    BR0388I Mounting volume P01B01 in device /dev/smc0 ...
    > OR "BR0388I Mounting volume P01B01 in device /dev/rmt1 ..." when using smc0
    BR0278E Command output of '/usr/sap/P01/SYS/exe/run/mount_tape.csh P01-B /dev/rm
    t1 P01B01':
    Moving medium: source 4096, destination 256...
    BR0280I BRBACKUP time stamp: 2008-10-24 17.15.07
    BR0279E Return code from '/usr/sap/P01/SYS/exe/run/mount_tape.csh P01-B /dev/rmt
    1 P01B01': 0
    BR0390I Mounting volume P01B01 in device /dev/smc0 failed
    brbackup profile:
    backup_dev_type = tape_box
    mount_cmd = "/usr/sap/P01/SYS/exe/run/mount_tape.csh $ $ $"
    dismount_cmd = "/usr/sap/P01/SYS/exe/run/dismount_tape.csh $ $"
    Edited by: Asep A on Nov 3, 2008 1:05 AM

    in script /usr/sap/P01/SYS/exe/run/mount_tape.csh, put only one line:
    exit 0

  • Job Created via SSRS Subscription Fails

    We are running a SQL 2012 server and have domain accounts configured for each SQL role.  After removing authenticated users from the Pre-Windows 2000 Compatibility Group in Active Directory (as recommended by an audit) we experienced issues where the
    SQL jobs could no longer run.  We found that the SQL agent account must be a part of this group as per the MS documentation as well as a few other permissions under user rights assignment.  Now that we have added that account back to the Pre-windows
    2000 compatibility group and added those permissions under user rights assignment, any job owned by any account other than the reporting account will run as expected.  Jobs as the reporting account configured in SQL Reporting Services Config Manager will
    not, and we cannot understand why. 
    The error is:  “The job failed.  Unable to determine if the owner (domain\sqlreporting) of job  has server access (reason: Could not obtain information about Windows NT group/user 'domain\sqlreporting', error code 0x5. [SQLSTATE 42000] (Error
    15404)).
    Can someone provide some insight as to how we may resolve, or what steps we may be missing?

    Hi TechQwest,
    According to your description, jobs owned by other accounts works fine, but those owned by service account of reporting services get the error.
    15404 is the exception when EXECUTE AS context cannot be impersonated. Reasons for this error are plenty:
    When the SQL Server instance does not have access to the AD server because is running as a local user or as 'local service'.
    When the SQL Server is asked to impersonate an unknown user, like the domain or user does not exit.
    In SQL Server Configuration Manager, SQL Server Reporting Services service is configured to run using an AD user account. SQL Server service was configured to run using a local Windows account. The SQL Server service (a local Windows user account) was trying
    to authenticate the user "domain\userName" in AD, which it could not do because it does not have the right/permission to access AD resources. If that is the case, we need to change the SQL Server service to us an AD user account, restarted the SQL
    Server and SQL Server Agent services, re-ran the SQL job.
    Log On account of SQL Server Agent and Owner of the job is not in the same domain. In this case, we need to set the Log On account of the SQL Server Agent to a domain account, then check whether the Owner of the job is set to the same domain user as the
    Log On account.
    If you have any more questions, please feel free to ask.
    Thanks,
    Wendy Fu
    Wendy Fu
    TechNet Community Support

  • Podcast Created Successfully but I did not receive the link

    Hi
    i am submit Podcast
    and received a message from the system that successfully
    Dear podcast owner, 
    Your podcast feed, [ http://mohamedtv.info/rss/kamal/ramadan2012/ramadan.xml ] was successfully added and is now under review.  
    Sincerely,  The iTunes Store Team
    but I did not receive the link Podcast ?

    It's here:
    http://itunes.apple.com/podcast/id546990813

  • Hyperion IR BQY job run successful few month but recently failed to export pdf and sending email

    Anyone have encountered the problem that the BQY jobs which are running more than 3 years successfully. But recently no one update the report, but the job export keep failing to send result pdf to receivers intermittently.
    It shouldn't be BQY job itself problem. Because this job has running years and fine. Only recent days comes out this problem. And user manually run the report can also be successful.
    After checking the server log, find out that Hyperion IR retrieved data successfully but export-excel/bqy type file all works except pdf format. And in one week, some day it works fine. Some day it failed.
    Trace in workspace job schedule log, it saying:
    Emailing section 'xxxxxx' as 'PDF' to:
    [email protected]
    [email protected]
    Export failed with unknown error.
    And checked the server_message_IRJobService.log it just saying:
    Error in export.[[
    And
    TCApp::ExecuteJavaScript failed:
    We stuck at this error for a period of time. Anyone can help? Oracle Support has mentioned it might be system performance issue. Will keep an eye on this issue, to see any solution can be find.

    Hi RamKumar,
    Thank you very much for your inputs. We haven't tried
    Increase the memory for the Hyperion Framework Services
    will test and see if it can solve the problem. For 'Hyperion Framework Service', do you mean 'Reporting and Analysis Framework'?
    We only tried increase the parameter of "Job Service" and "Intelligence Service" which called Dynamic Service Properties set to "PROCESS_MEMORY_LIMIT=2500MB". But seems hyperion this 32bit application only can reach to 2047MB.
    Our EPM version is 11.1.2.1.600.07.
    a. We have increased the memory from 24G to 48G and add more memory for JobService (now it has 2 GB memory).
         For the provided solution.
         Set the filters in the query to return smaller amount of data
         We are still working on, but it seems slightly solve the "Error in export" problem.
    b. We have confirmed the SMTP Server configuration is correct. So this solution not fit for our case. As the trouble job has been running more than 3 years, until recent month it starts with this error. And the job failed this error only happens intermittently e.g. Monday,Tuesday,Friday it all works fine(Proved the job it self is OK) but Wednesday some period, it failed to export. So we are thinking it might the hyperion performance issue.
    For the KM reference:
    Interactive Reporting (IR) Jobs do not Send Emails. Error: "Export failed. Error Sending Mail" (Doc ID 1401854.1)
    We have already read and checked, we do have correct configuration.
    Interactive Reporting Job Completing With Javascript Errors - Not Producing Excel Output (Doc ID 1065483.1)
    Our case is customer can successful extract data and send excel/bqy result to customer with no problem. But it failed to send pdf result sometime.
    Thanks and Regards,
    Erica

  • Creating job, ran successfuly, but not seen on dba_scheduler_jobs

    Hello working on 10g standard Edition on windows, I'm created an inline job but to execute an OS commend, but this doesn't show up why?
    conn dev@souceb
    Example:
    begin
    dbms_scheduler.create_job(job_name =>'EXEMPLE',job_type =>'executable',enabled => true,start_date => SYSTIMESTAMP,job_action =>'c:\temp\cp.cmd');
    end;
    PL/SQL procedure successfully completed.
    SQL> select job_name from dba_scheduler_jobs;
    JOB_NAME
    AUTO_SPACE_ADVISOR_JOB
    GATHER_STATS_JOB
    FGR$AUTOPURGE_JOB
    PURGE_LOG
    RLM$SCHDNEGACTION
    RLM$EVTCLEANUP
    RS_RESTRICT_ACCESS_90DAYS_JOB
    the job EXEMPLE doesn't show up, and when Itry to launch the job, I have the following error
    EXEC DBMS_SCHEDULER.RUN_JOB('EXEMPLE',TRUE);
    ERROR at line 1:
    ORA-27475: "DEV.EXEMPLE" must be a job
    ORA-06512: at "SYS.DBMS_ISCHED", line 150
    ORA-06512: at "SYS.DBMS_SCHEDULER", line 441
    ORA-06512: at line 1
    Could someone helps me for this?
    Thanks

    I don't what really is going on with my system but the creation of the job works fine, but I'm getting this error:
    SQL> EXEC DBMS_SCHEDULER.RUN_JOB ('MYJOB');
    BEGIN DBMS_SCHEDULER.RUN_JOB ('MYJOB'); END;
    ERROR at line 1:
    ORA-27370: job slave failed to launch a job of type EXECUTABLE
    ORA-27300: OS system dependent operation:accessing execution agent failed with
    status: 2
    ORA-27301: OS failure message: The system cannot find the file specified.
    ORA-27302: failure occurred at: sjsec 6a
    ORA-27303: additional information: The system cannot find the file specified.
    ORA-06512: at "SYS.DBMS_ISCHED", line 150
    ORA-06512: at "SYS.DBMS_SCHEDULER", line 441
    ORA-06512: at line 1
    other reason gotten from the dba_scheduler_job_run_details:
    select status,run_duration,session_id,additional_info from dba_SCHEDULER_JOB_RUN_DETAILS where job_name='MYJOB';
    ORA-27370: job slave failed to launch a job of type
    EXECUTABLE
    ORA-27300: OS system dependent operation:accessing
    execution agent failed with status: 2
    ORA-27301: OS failure message:
    The system cannot find the file specified.
    ORA-27302: failure occurred at: sjsec 6a
    ORA-27303: additional information: The system cann
    ot find the file specified.
    Any tips?
    Thanks

  • How to send e-mail alert to the user job is successful or failed.

    Hi Experts,
    I have scheduled a job using DBMS_JOB Package; in this job I am calling a procedure.
    How can we send an e-mail(alert) to the user if the job is successful (or) job fails.
    If the job is successfully completed, then we have to send mail as “Job is completed successfully along with job name”.
    If the job fails we have to send email as “error message of the job along with job name”(why the job is failed).
    This alert should be sending automatically no manual intervention.
    Please help me.
         CREATE OR REPLACE PROCEDURE APPS_GLOBAL.arc_procedure (P_ID IN NUMBER)
         IS
         CURSOR C IS SELECT id,table_name,archive_table_name,where_condition
         FROM apps_global.control_ram
         WHERE id = p_id
         ORDER BY id, table_name;
         BEGIN
            FOR I IN C
            LOOP
               EXECUTE IMMEDIATE
                  'INSERT INTO '
               || I.ARCHIVE_TABLE_NAME
               || '
         (SELECT * FROM '
               || I.TABLE_NAME
               || ' WHERE '
               || I.WHERE_CONDITION
               || ')';
               EXECUTE IMMEDIATE
                  'DELETE FROM '
               || I.TABLE_NAME
               || ' WHERE '
               || I.WHERE_CONDITION
               || '';
               COMMIT;
            END LOOP;
         EXCEPTION
            WHEN OTHERS
            THEN
               ROLLBACK;
               DBMS_OUTPUT.PUT_LINE (
               'An error was encountered - ' || SQLCODE || ' -ERROR- ' || SQLERRM);
         END arc_procedure;
         /This is my job.
    DECLARE
      X NUMBER;
    BEGIN
      SYS.DBMS_JOB.SUBMIT
      ( job       => X
       ,what      => 'APPS.arc_procedure(1);'
       ,next_date => to_date('05/01/2013 00:00:00','dd/mm/yyyy hh24:mi:ss')
       ,interval  => 'TRUNC(SYSDATE+1)'
       ,no_parse  => FALSE
      SYS.DBMS_OUTPUT.PUT_LINE('Job Number is: ' || to_char(x));
    COMMIT;
    END;
    /Thanks in advance.

    Hi,
    I think you can do by creating mailing procedures and call it in the loop and outside the loop.
    There would be two procedure one in inside loop which will execute after successfull completion of the loop.
    Other would be in the exception block like i shown in the below code you have written;
    V_variable_1 you can use as a parameter for what is the error occured.
    like suppose your mailing procedure name is Status_email and Status_email_1.
    CREATE OR REPLACE PROCEDURE APPS_GLOBAL.arc_procedure (P_ID IN NUMBER)
         IS
         CURSOR C IS SELECT id,table_name,archive_table_name,where_condition
         FROM apps_global.control_ram
         WHERE id = p_id
         ORDER BY id, table_name;
    V_VARIABLE_1 NUMBER;
    V_VARIABLE_2 VARCHAR2(400);
         BEGIN
            FOR I IN C
            LOOP
               EXECUTE IMMEDIATE
                  'INSERT INTO '
               || I.ARCHIVE_TABLE_NAME
               || '
         (SELECT * FROM '
               || I.TABLE_NAME
               || ' WHERE '
               || I.WHERE_CONDITION
               || ')';
               EXECUTE IMMEDIATE
                  'DELETE FROM '
               || I.TABLE_NAME
               || ' WHERE '
               || I.WHERE_CONDITION
               || '';
               COMMIT;
                     STATUS_EMAIL;
            END LOOP;
         EXCEPTION OTHERS THEN
    V_VARIABLE_1 :=SQLCODE;
    V_VARIABLE_2 :=SQLERRM;
               ROLLBACK;
    STATUS_EMAIL_1(V_VARIABLE_1,V_VARIABLE_2);
         END arc_procedure;
         / You can refer to sample email procedure i have created for you.
    CREATE OR REPLACE PROCEDURE STATUS_EMAIL
    AS
       v_From       VARCHAR2(80) := 'EMAIL_ID';
       v_Recipient  VARCHAR2(80) := 'EMAIL_ID';
    --YOU CAN SEND EMAIL TO MORE THAT ONE USER SO YOU CAN USE LIKE BELOW VARIABLE....
       v_Recipienttt  VARCHAR2(80) := 'EMAIL_ID';
       v_Subject    VARCHAR2(80) := 'SUBJECT_FOR_THE_MAIL';
       v_Mail_Host  VARCHAR2(30) := 'MAIL_SERVERS_HOST_IP(SMTP_SERVER)';
       v_Mail_Conn  utl_smtp.Connection;
       crlf         VARCHAR2(2)  := chr(13)||chr(10);
    BEGIN
      v_Mail_Conn := utl_smtp.Open_Connection(v_Mail_Host);
      utl_smtp.Helo(v_Mail_Conn, v_Mail_Host);
      utl_smtp.Mail(v_Mail_Conn, v_From);
      utl_smtp.Rcpt(v_Mail_Conn, v_Recipient);
      utl_smtp.Rcpt(v_Mail_Conn, v_Recipienttt);
    --OPEN DATA CONNNECTION
      UTL_SMTP.OPEN_DATA(v_mail_conn);
    --MAIL HEADER
      utl_smtp.write_DATA(v_Mail_Conn,'Date: '   || to_char(sysdate, 'DD-MON-YYYY hh:mi:ss AM') || crlf);
      utl_smtp.write_DATA(v_Mail_Conn,'From: '   || v_From || crlf );
      utl_smtp.write_DATA(v_Mail_Conn,'Subject: '|| v_Subject || ||crlf);
      utl_smtp.write_DATA(v_Mail_Conn,'To: '     || v_Recipient || crlf);
      utl_smtp.write_DATA(v_Mail_Conn,'Cc: '       || v_Recipienttt ||','|| crlf);
    --MAIL BODY
      utl_smtp.write_DATA(v_Mail_Conn,'MIME-Version: 1.0'|| crlf );
      utl_smtp.write_DATA(v_Mail_Conn,'Content-Type: multipart/mixed;'|| crlf );
      utl_smtp.write_DATA(v_Mail_Conn,' boundary="-----SECBOUND"'|| crlf ||crlf );
      utl_smtp.write_DATA(v_Mail_Conn,'-------SECBOUND'|| crlf );
      utl_smtp.write_DATA(v_Mail_Conn,'Content-Type: text/plain;'|| crlf);
      utl_smtp.write_DATA(v_Mail_Conn,'Content-Transfer_Encoding: 7bit'|| crlf);
      utl_smtp.write_DATA(v_Mail_Conn,'Procedure is successfully complited without error'|| crlf);
      utl_smtp.write_DATA(v_Mail_Conn,null|| crlf);
      utl_smtp.write_DATA(v_Mail_Conn,null|| crlf);
    utl_smtp.write_DATA(v_Mail_Conn,null|| crlf);
      utl_smtp.write_DATA(v_Mail_Conn,'Dear All, '|| crlf);
      utl_smtp.write_DATA(v_Mail_Conn,'Procedure is successfully complited without error'||'.' ||crlf);
      utl_smtp.write_DATA(v_Mail_Conn,null|| crlf);
      utl_smtp.write_DATA(v_Mail_Conn,null|| crlf);
      utl_smtp.write_DATA(v_Mail_Conn,null|| crlf);
      utl_smtp.write_DATA(v_Mail_Conn,null|| crlf);
      utl_smtp.write_DATA(v_Mail_Conn,'Regards, '|| crlf);
      utl_smtp.write_DATA(v_Mail_Conn,null|| crlf);
      utl_smtp.write_DATA(v_Mail_Conn,'any_name '|| crlf);
      utl_smtp.write_DATA(v_Mail_Conn,null|| crlf);
      utl_smtp.write_data(v_Mail_Conn, utl_tcp.CRLF ||'This mail is auto generated.');
      --CLOSE CONNECTION
      UTL_SMTP.CLOSE_DATA(v_mail_conn);
      utl_smtp.Quit(v_mail_conn);
    EXCEPTION
      WHEN utl_smtp.Transient_Error OR utl_smtp.Permanent_Error then
        raise_application_error(-20000, 'Unable to send mail: '||sqlerrm);
    END;
    /cheers..

Maybe you are looking for

  • Material Clasification details Table

    Hi, I am not able to get the numeric type values of a characteristic from the table CAWN. I have naterial number, class number. Based on these two, i want tofetch the Characterstic values. Please let me know how to fetch the char values. Thanks in ad

  • How do I get MacBook Air to see Windows Home Server and show it in Finder?

    New to Mac (having used Windows for years) so this may be a dumb question. Have a MacBook Air (new) and have a home network with a Windows Home Server on the network. I can't figure out how to get the MacBook Air to see the Windows Home Server. It do

  • Media query

    Hi everyone I m having a little program with a website which I m putting together. The site is at this url address. http://www.dreamaustraliastudytours.com.au/Test/index102/index.html. ' So far I have built up the following media query: @media only s

  • Problem to change the domain

    Hi, I am to change the domain in the client machine but I have got this On the client, I am able to ping the domain and I've also put the IP of the domain server as DNS server like Many Thanks & Best Regards, Hua Min

  • Run Button without execute the program

    Hi, Normally, when I am pressing the "run button", it will run the program. How do I prevent from executing the program until I want to enable? For example, I have 3 power supplies on my pxi box, and I don't want to run the program until I have all m