How to identify time taken to execute a package

Hi all,
Is the method without TKPROFF to find the time taken to execute a package that calls a procedure.
for examples
Lets says I execute a packaage at SQLplus window
SQL> Execute my_pack.bal_proc;
(It took some time may be 4 hrs to excecute according to my watch).
At this stage if I want to find the time by some sql command that after executing the package what was the time.
can someone help me in finding a query that tell what was the time taken to execute a package.
thanks n rgds
saaz

You can check start and end time
Then end time -start time
SQL> select systimestamp start_time from dual;
START_TIME
11-AUG-09 11.30.47.758282 AM -04:00
SQL> Execute my_pack.bal_proc;
SQL> select systimestamp end_time from dual;
END_TIME
11-AUG-09 11.31.11.207530 AM -04:00Edited by: user5495111 on Aug 11, 2009 8:32 AM

Similar Messages

  • TIme taken to execute query

    Hi,
    HOW TO FIND OUT TIME TAKEN TO EXECUTE SELECT QUERY IN SAP, SAY FOR EXAMPLE
    SELECT * FROM MARA WHERE MATNR BETWEEN '100' AND '1000'.
    HOW TO PRINT TIME TAKEN TO EXECUTE ABOVE QUERY i.e. TIME IN MICROSECONDS...
    IF YOU HAVE SAMPLE PROGRAM THEN PLEASE LET ME KNOW.
    THANKS,
    JOHN.

    just declare.
    END-OF-SELECTION.
      GET TIME.
      end_dt = sy-datum.
      end_tm = sy-uzeit.
    <b>ex--</b>
    select * from ekko into table ekko.
    get time.
    t1 = sy-uzeit.
    select * from ekko into table ekko.
    get time.
    t2 = sy-uzeit.
    write :/ t1.
    write :/ t2.
    diff = t2 - t1.
    write :/ 'Time Taken : ' , diff.

  • How to Measure time taken for a some lines of code in a program?

    Hi
    I have one requirement to measure time taken for executing a  block of code in report . How we can find it ?
    Is there any way to code something in report to caluculate it ?
    Please send solution as early as possible
    thank u

    Ok.. try this code...
    DATA : t1 TYPE i,
    t2 TYPE i,
    delta(16) TYPE p.
    GET RUN TIME FIELD t1.
    PERFORM get_data. "your block of code
    GET RUN TIME FIELD t2.
    delta = t2 - t1.
    delta = delta / 1000000.
    WRITE :/ 'Time elapsed : ', delta , 'Secs'. "time in secs.

  • Time taken to execute my report?

    Hi Expects,
    I want to print in the output how much time taken to execute my report. Please help on this.
    regards,
    vijay

    Hi vijay,
    1. simple
    2. we have to use two things to get Current time.
       GET TIME
       SY-UZEIT.
    3.
    report abc.
    data : t1 type sy-uzeit.
    data : t2 type sy-uzeit.
    data : diff type i.
    data : ekko like table of ekko with header line.
    get time.
    t1 = sy-uzeit.
    select * from ekko into table ekko.
    select * from ekko into table ekko.
    get time.
    t2 = sy-uzeit.
    write :/ t1.
    write :/ t2.
    diff = t2 - t1.
    write :/ 'Time Taken : ' , diff.
    regards,
    amit m.

  • Time taken to execute code vs time taken to render to screen....

    Hello Experts,
    I noticed something strange while debugging some of my code.
    I have a for loop in which I'm creating and adding node elements. Above the for loop I'm creating a modal window, and after the for loop I'm destroying the modal window. In the modal window I have a timedtrigger element with a delay of one second.
    Here is the pseudocode:
    createModalWindow();
    for(int i=0; i<200; i++)
        // create and add node elements
    destroyModalWindow();
    Inside the modal windows wdDoInit() method I enable the timedTrigger, inside the wdDoExit() method, I disable the timedTrigger.
    When I execute this code I get a null pointer exception because the application is trying to destroy a window instance that doesn't exist!!! ie the modal window. When I comment out the destroyModalWindow() line, I noticed that the modal window get rendered after the loop has finished its processing not before like I'd expect. Could this mean the line destroyModalWindow(); is being called too early? Once the loop has processed there might be some clinet / server delay?? Another thing I noticed was the timed trigger event, even though its set to a 1 second delay, takes about 6 seconds on a round trip from the client to Web Application Server!!!! So even though on the WAS its processing it every second, it takes almost 6-7 seconds for it to render on the client browser!
    Has anyone else noticed this delay in rendering to code execution? Is it possible the Web Dynpro may terminate earlier than expected or sometimes we might not even see the results because time taken to render is slower than time taken to process request?
    What are peoples' thoughts?
    MM

    Sorry if I misinterpret your question...
    Remember Web Dynpro is server side technology. So no actual rendering happens at all until all code has been executed, then wdDoModify is called, and then output is generated and sent to the browser for rendering. Of course I can't see your code in it's completion, but the modal window should never display under any circumstances, as the call to create() and then destroy() happen within the same execution cycle, from what I can tell of your snippet.

  • How  to find time taken any  portal component to load into the  portal

    Hi
    We have MSS business package implement in Nw04 sp18 portal. Some of MSS forms taking so much time to load.so
    1. is there any way to test the time taken by each of the  form?
    2. In Portal how to measure the time taken by the each request?
    3.How to improve the performance of MSS adobe forms?
    Regards
    Gopal

    Hi Gopal,
    You can use HTTPWatch to determine the time taken by each form to load as well as the portal request time. Also check this documentation. This should apply to MSS also.
    http://help.sap.com/saphelp_nw70/helpdata/en/52/01fc3f17c2c342e10000000a1550b0/frameset.htm
    Hope this helps.
    Akhilesh

  • How to find time taken for a search

    hi all,
       I need to find the time taken for a particular search in KM Search iView. I refered the following thread
    /message/5739737#5739737 [original link is broken]
    but not able to get the duration(time taken). is there any other way to achieve this?.
    all helps will be appriciated.
    Regards,
    Shanthakumar.

    Hi Shantakhumar,
    do you want to implement you own Search iView?
    Best regards,
    Denis

  • How to identify no of queries executed by a user in a given time

    Hi All,
    version 11g
    os Linux 5.6
    Am trying to find out total number of queries executed by a user in 30min of time. This information is required to understand how many queries are getting executed by application for the analysis purpose.
    Could some one help me to get this information.
    Thank you very much in advance.
    Best Regards
    Mvk

    Dear Vlethakula,
    I tried query below query
    select sql_id,TO_CHAR(sample_time,'MM-DD-YYYY HH24:MI:SS') from dba_hist_active_sess_history where snap_id in
    (select snap_id from dba_hist_snapshot where sample_time between to_date('02-19-2013 19:00:00','MM-DD-YYYY HH24:MI:SS') and
    to_date('02-19-2013 20:00:00','MM-DD-YYYY HH24:MI:SS'))
    and user_id='572'
    {code }
    But when i see in  awr report number of executions were more .
    Ex: i tried above query and got output as 1880
    During same time period for the same query(accessed only by this user from application) in awr it is showing 16000 executions.
    Am i doing some thing wrong?
    Thank you very much
    Regards
    Mvk                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • How to see time taken of the footage in premier pro cs5

    Hi,
    I have captured the video footage from miniDV tape and brought it in premier pro cs5. I want to see the time at which the actual footage was recorded, not the file created or modified. For eg, 12th march, 2011 at 1.24PM. I tried to look under project panel and expanded it by pressing ~ key. On the right hand top fly out menu, pressed Metadata Display and searched under Premier pro project data and Basic. Couldn't find the right property to add. Any help appreciated.

    Window | Metadata
    -Jeff

  • How to reduce Time taken by DSO Activation.

    Hi
    My Inventory Transaction DSO taking nearly 18min for 180,000 records to activate. It means it takes 1 min for every 10,000 records to activate. I think its too much.
    Is there any way i can reduce DSO activation time... what are factors that increases the DSO activation Time.
    Pls let me know if u have some idea  this issue.
    Thanks.....

    Hi,
      Some of the factors which affect DSO activation are
    1) Data volume and size of DSO (if the volume and no of fields are more then it takes long time)
    2) SID generation(uncheck this if the DSO is not used for reporting)
    3) Secondary index (remove unwanted secondary index)
    4) No of background jobs and packages siz allocated for activation (check the settings for ur DSO in tcode RSODSO_SETTINGS)
    Apart from this it also depends on database performance and other factors
    Regards,
    Raghavendra.

  • How to analyse the time taken for a query

    Hey gurus ,
                          How to find the time taken for a query to execute .
    Regards,
    Venkatesh

    Hi,
    Time taken to execute a query = FRONT END TIME + OLAP TIME + DB TIME.
    front end time is time taken to do format in BEX.
    olap time is time taken to aggegate data in OLAP buffer.
    db time is tme taken to collect data at data target.
    to fine all these information
    goto RSRT -> give query name -> execute+debug -> it will display all the fields > check fields what ever u want.
    Regards,
    Haritha.

  • How we can store start time & end time taken by execution of scenerio?

    Hi
    i want to store starting time and ending time taken by executing of any scenerio and date also on which scenerio will be executed.
    plz assist me regards the same
    thanks

    when you say store , you want to capture in some file ,email or table.
    If table , you can have a small sql linking SNP_SESSION and SNP_SCEN and fetching the required detail accordingly.

  • Query Execution time - Elapsed time v Actual time taken

    Hi All,
    I have this scenario where I am querying a single table with the following results. It is a very heavy query in that there are multiple aggregate functions and multiple unions on it. Even if the query is written poorly (i doubt it is) why would the actual
    time taken to execute the query be much more than the statistics provided through the following commands?
    SET STATISTICS IO ON;
    SET STATISTICS TIME ON;
    Attached are the stats provided for the relevant query in question.
    Table '123456789_TEMP_DATA'. Scan count 178, logical reads 582048, physical reads 0, read-ahead reads 0, lob logical reads 0, lob physical reads 0, lob read-ahead reads 0.
    Table 'Worktable'. Scan count 0, logical reads 0, physical reads 0, read-ahead reads 0, lob logical reads 0, lob physical reads 0, lob read-ahead reads 0.
    SQL Server Execution Times:
       CPU time = 936 ms,  elapsed time = 967 ms.
    2014-01-06 17:36:41.383
    Now, although the CPU Time/Elapsed time shows that it takes less than a second, it actually takes more than 15 seconds to fetch the results. (This is the actual time that you get on the bottom bar of the Query pane as well.)
    What is the reason? Why is it that there is such a big discrepancy between the numbers? How can I improve this situation?
    Thanks!

    Yes. I am returning a huge number of rows to the client. 
    The query is simply against a single table. 
    Select
     'First Record',AVG(COLUMN1),STDEV(COLUMN1
    ),COUNT(COLUMN1)
    FROM [TABLE1] WHERE (SOME CONDITION)
    UNION ALL
    Select  'Second Record',AVG(COLUMN2),STDEV(COLUMN2),COUNT(COLUMN2) FROM [TABLE1]
    WHERE (SOME OTHER CONDITION)
    Imagine there are 178 records fetched in this manner with 178 UNIONs. The WHERE clause will always change for each SELECT statement.
    Now, the question is not so much about the query itself, but why the execution time is actually 15 seconds whilst the SQL STATISTICS show it to be 936ms (<1 second)
    Thanks!

  • Time taken for a method to run. ?

    I have a query regarding ascertaining the time taken
    for a method to execute
    I have a SQL statement that I reads 10,000 rows.
    String a_SQL = "Select.....from TableA";
    try {
         IQuery query = m_UC.createQuery();
         SimpleTableModel stm = query.executeSelect(a_SQL);
       }catch(SQLException se){
       // Query Over.
       private void displayJTable(){
       // display rows read from the query above.
       }          As the query is executing,I want to display a progress bar
    showing the status of the query.
    Now I cant use this :
    start = System.currentTimeMillis();
    try {
         IQuery query = m_UC.createQuery();
         SimpleTableModel stm = query.executeSelect(a_SQL);
       }catch(SQLException se){
    end = System.currentTimeMillis();
    System.out.println(" Time taken  to display " + (end - start)/1000);
                  The above will give me the time elapsed in seconds for the SQL query to execute,but
    this is not what I want.
    What i want is to use this :
           // Progress BAR executing,so I need to get to know the time
           // taken for the query to run
            try {
            the SQL execution
            }cach(){
            // Query over.
            // Stop Progres Bar.
            // Display JTable.       How can I know when to stop the Progress Bar as I have no handle
    on the time taken to execute the query?
    Any help will be appreciated

    You can have a separate thread (or maybe it's just part of the regular GUI update thread? I don't know details about GUIs) that puts up an hourglass or spinning clock hands or dancing hamster or whatever to indicate that something is going on, but like the man says, you can't know ahead of time how long it will take to run a query, so you can't show percent done. You also don't in general know ahead of time how many rows will be returned so that doesn't help you.
    You might be able to do something for the processing of the returned data, once the query completes, because then you can often get a count of the number of rows, so you process each row in a loop, and update the % done counter each time through the loop.

  • How to Identify Last  Command Issued by user??

    Hi Everybody,
    I need to create a form in which the current state of the form depends upon the last command issued by the user.
    Suppose if user clicks 'delete record' or 'insert record' or 'enter-query' or something else.
    So, how to identify the last event executed by the user.
    Any suggestions...
    Thx in advance,
    Raj

    You can write something into a Form parameter in the POST-INSERT/UPDATE/Query triggers.
    Then you can check the value of this parameter when needed.

Maybe you are looking for