How to identify the name of the procedure that inserts into a table in the TRIGGER

Hello
There are several procedures in my DB that perform the INSERT operation on a main table - MYTAB say.

I created a trigger on the table MYTAB, to follow closely, what procedure is insert data in there. Is there a function that captures the name of this object?

For example: PROC_A, PROC_B, PROC_C insert into the table MYTAB. And my query is - the trigger on table MYTAB should document these object names where the lines fit.
Please let me know your suggestions...

SQL> create table t (no integer, dt timestamp, who_inserted varchar2(4000));

Table created.

SQL> create or replace procedure p
  2  as
  3  begin
  4    insert into t (no, dt) values (1, systimestamp);
  5  end;
  6  /

Procedure created.

SQL> show err
No errors.

SQL> create or replace trigger t_trig before insert on t for each row
  2  begin
  3     :new.who_inserted := dbms_utility.format_call_stack;
  4  end;
  5  /

Trigger created.

SQL> show err
No errors.

SQL> begin
  2    p;
  3  end;
  4  /

PL/SQL procedure successfully completed.

SQL> select * from t;

        NO DT                             WHO_INSERTED
---------- ------------------------------ ----------------------------------------
         1 31-OCT-14 04.58.53.668465 AM   ----- PL/SQL Call Stack -----
                                            object      line  object
                                            handle    number  name
                                          3a7ddbea0         2  KARTHICK.T_TRIG
                                          3ac979f30         4  procedure KARTHICK.P
                                          3a822deb8         2  anonymous block

Tags: Database

Similar Questions

  • How to identify the virtual copies (in my records) that have already been deleted a collection

    Hello!

    I keep looking for an answer to this anywhere on the web and 3 books, but can't find the answer...

    How to identify the virtual copies (in my records) that have already been deleted a collection?

    Here's the workflow, and where I'm stuck.

    1. I chose a picture and put it in a collection.

    2. I did a whole bunch of virtual photos in the collection copies that I tried different modifications.

    3. after and during a lot of changes, I have a lot of virtual copies removed from my collection because I decided against the changes after doing some comparisons.

    4. when I went the folders to select my next picture to work away and so to add to the collection, I discovered that each of my virtual copies was in the original folder, even if I had deleted from my collection.

    5. I really don't want these virtual copies deleted to be in my home folder.  They were virtual copies of trial and error and I wanted them to really just be thrown out.

    6. how to identify these virtual copies removed-from-the-collection in my folder?  File names all look the same, and besides, I want to be absolutely certain that I have selected the right ones.  Some of the changes were very minor and would be difficult to see without laboriously go through them one by one.

    Thank you very much!!

    Anne

    No easy answer on fixing the mess other than an individual inspection of the virtual copy can't watching the Images/Edit history to determine which ones that you no longer need.

    But to help prevent the problem in the future: when you are working from a collection, you must use ALT + return back to remove a copy of Photo or virtual catalog. With just the key DELETE or BACKSPACE only deletes the photo from the collection.

  • How to identify the fonts used in text format?

    How to identify the fonts used in text format?

    Hi DSB.

    Open the document in Reader, go to the menu file-> properties, then click on the tag are. You will see a list of the fonts used in the document.

    Another option is to copy the text and paste it into MS Word, where you can simply move your mouse over the text to display the name of the font.

    Kind regards

    Nicos

  • How to identify the primary Parent of a shared node?

    We have a property that is set to Local defined, inherit,

    Suppose the 'Color' property and currently is the behavior in DRM

    Parent A - blue

    Child 1 - blue (inherited from Parent)

    Child 2 - color blue (inherited from Parent)

    Child 3-color blue (inherited from Parent)

    Parent B - Red

    Child 3 ~ part 1 - red color (inherited from Parent B)

    Child 4-color red (inherited from Parent B)

    Children 5 - red color (inherited from Parent B)

    The customer has improved the requirement so that in the case of shared members 'color' is inherited from the primary parent like the example below.

    Parent B - Red

    Child 3 ~ action1 - blue (inherited from "Primary" Parent A)

    Child 4-color red (inherited from Parent B)

    Children 5 - red color (inherited from Parent B)

    I guess I'm going to need a new property like 'Primary colors' and I need to write a formula to calculate the color of base on the primary parent.  However, I do not know how to identify the "main Parent" a shared node we use version 11.1.1.2 N-Tier

    I'm looking for suggestions on how to calculate the value of the property you want.

    Any help will be greatly appreciated.

    Hello

    You can create a new property derived like u said and use instead of the property defined in your exports or anywhere where you have to refer to the color. The property set can be used just to take the user input.

    The new derived property should be a logic like that-

    If (PropValue (Core.SharedFlag_MDM),

    NodePropValue (PropValue (Core.PrimaryName_MDM), Custom.Colour)

    PropValue (Custom.Colour))

    Now, 11.1.1.2 I lost the memory of how the properties are referred to as - if they are just used with their names or namespaces is mentioned (Core. , custom.). You can change the formula accordingly to view properties

    Thus, if SharedFlag_MDM is True, then it will take the value of the property to its primary node, which is inherited from the primary parent and if the shared flag is False then it is just a varValeurProp on the node itself.

    I hope that answers you.

    Thank you

    Denzz

  • How can identify the real space in my SGPT123 Tablet?

    Hello

    How can identify the real space in my Xperia Tablet? I can see only 10.0 GB, if suppose has 16 GB, where's the rest?

    A space is medical, the Android operating system and recovery Partition.

  • C: drive is running out of space, even if I moved everything I could to the E: drive. How to identify the "space Eater"?

    I moved all my data to the other disk. I was installing new programs on the other disk. Yet, the space on drive C: (37 GB) keeps becoming 'used '. Free space now is 2%. How to identify the "space Monster" which takes more and more the training?

    37GB is size sorry for C:.  My minimum recommendation for everything that came out at the time of and after Windows Vista is 60 GB.

    JDiskReport
    http://www.jgoodies.com/freeware/JDiskReport/index.html

  • How iterate/identify the screens of the application stack

    Hi all

    1. work on the version of BB storm (9500/9530 Simulator) is v4.7.0.75
    2 opportunity BB JDE 4.7

    3. the request is:

    In my application I have screens showns one based on the click number, how can I display no matter which screen every time I required.i tell how fetch/identify the battery and display.

    Thanks in advance

    Ratna

    I donno what are your exact needs...

    If you want to load screens on selcting a menuitem from the GUI go to create menuItem.

    In the case depends on certain conditions of your application then just use

    try
      {
           UiApplication.getUiApplication().pushScreen(TestScreen);
      }
    
    catch(Exception e)
    {
    // PUSH screen fails because the screen was already pushed.
    // remove the screens from top of the required screen.
    while(UiApplication.getUiApplication().getActiveScreen() != TestScreen)
    
      {
         UiApplication.getUiApplication().popScreen();
      }
    }
    
  • How to identify the iSCSI nodes?

    How to identify the iSCSI nodes?

    with IQN

  • How to identify the Protocol of network storage using PowerCli

    Hi all

    Does anyone know how to identify the network storage protocol using Powercli? If you do could you please point me in the right direction and appropriate controls to be used.

    Thank you.

    See you soon

    With the Get-EsxCli cmdlet, you get to many of the features esxcli.

    Something like that

    $esxcli = Get-EsxCli -VMHost MyEsx$esxcli.storage.core.path.list()
    

    You can use Select-Object to choose the specific properties of the returned objects.

    For example

    $esxcli = Get-EsxCli -VMHost MyEsx$esxcli.storage.core.path.list() | Select RuntimeName,Transport
    
  • How to identify the serial number for the instalation?

    How to identify the serial number for adobe photoshop cs5?

    http://helpx.Adobe.com/x-productkb/global/find-serial-number.html

  • How to identify the expressions of folklore in the lot while reading File adapter

    Hello
    I have a bepl process to read data from a batch of 100 records text file and write in an Oracle EBS interface table.
    After the completion of the above, I have to call a partner link.
    Problem here is that, how to identify the expressions of folklore, so that I could call my link partner in BPEL.
    How do I get there? Any help is greatly appreciated.

    Hello

    You can implement a separate process, say FileNotificationProcess, you call the link partner, based on the batch Manager wsdl to $ORACLE_HOME/bpel/system/xmllib/jca/BatchManager.wsdl. This new process would be notified of different States of the file reading activity:
    # onBatchReadStart - indicates when a file is started to read
    # onBatchReadComplete - indicates when a file is done playing
    # onBatchReadFailure - tells when a record cannot be processed by the infrastructure of adapters.
    In your case, you would call the partnerlink when a notification of "onBatchReadComplete" is sent.

    In your main process to the file adapter, add the below property, so that the file adapter would inform the new process of the different stages of the processing of batch file.

    bpel://default|FileNotificationProcess
    

    This is described in detail in BPEL best practices guide page 3-18 http://download.oracle.com/technology/tech/soa/soa_best_practices_1013x_drop3.pdf and the article excellent blog of anthony at http://blogs.oracle.com/reynolds/2008/06/more_on_batch_processing_in_bp.html.

    Kind regards
    Yohanna.
    http://www.prshanmu.com/articles/

  • Insert into a table using the check boxes

    Hello

    I want to insert into a table emp when I press a button "Insert" area of employee report. the SQL query for the report is

    SELECT HTMLDB_ITEM. CheckBox(1,rowNum) "",
    x.EmpNo,
    x.Ename
    de)
    Select empno htmldb_item.hidden(2,empno),
    htmldb_item. Text(3,Ename) ename from emp) x
    order by 2

    I created the following process:

    declare
    v_test varchar (10);
    Start
    BECAUSE me in 1.HTMLDB_APPLICATION. G_F01. COUNTY
    LOOP
    v_test: = HTMLDB_APPLICATION. G_F02 (HTMLDB_APPLICATION. G_F01 (i));
    dbms_output.put_line (v_test);
    insert into emp(empno,ename,job,mgr,hiredate,sal,comm,deptno)
    values(v_test,'A','B',10,01-May-81,200,1,10)
    WHERE empno = HTMLDB_APPLICATION. G_F02 (HTMLDB_APPLICATION. G_F01 (i));
    END LOOP;
    end;

    But IT is not working properly, infact, it gives me errors like:

    ORA-06550: line 9, column 47:
    PL/SQL: ORA-00933: SQL not correctly completed command
    ORA-06550: line 8, column 1:
    PL/SQL: SQL statement ignored

    7 dbms_output.put_line (v_test);
    8 insert into emp (empno, ename, job, mgr, hiredate, sal, comm, deptno)
    9 values(v_test,'A','B',10,01-MAY-81,200,1,10)
    10 WHERE empno = HTMLDB_APPLICATION. G_F02 (HTMLDB_APPLICATION. G_F01 (i));
    11. END OF LOOP;

    Any help?
    Additional info: table Emp is the default table in the database

    This is an example showiing how such a process must be put in place:

    http://Apex.Oracle.com/pls/OTN/f?p=31517:95

    Denes Kubicek
    -------------------------------------------------------------------
    http://deneskubicek.blogspot.com/
    http://www.Opal-consulting.de/training
    http://Apex.Oracle.com/pls/OTN/f?p=31517:1
    -------------------------------------------------------------------

  • How to add text on an image that is inserted into a table in Dreamweaver

    I am relatively new to dreamworks and I saw the easiest way so far is the use of tables to make your layouts, I wonder if there is a way where you can insert text on (in front of) an image that fits into a table?

    Easy and best are not synonymous.  The best way to create modern web pages is no tables with CSS layouts.   If someone told you of tables are better, they are ill-informed, out-of-touch and/or you are looking at a tutorial very old.

    Getting back to your original question, put your image in the background with the CSS code.

    CSS background-image property

    If you are not familiar with HTML and CSS code, you will need to do some homework first.  He had to learn to get the most out of Dreamweaver.

  • How to identify the name of the cluster to run the createresourcepool script?

    I want to manage the resource in ESX 4.1 Pool.

    And fortunately, I found a script from here, written by William Lam in 28/11/09.

    Lam, Hello, how are you?

    I want to test your code, but I don't know how to use it.

    I mean, I have a machine ESX, alone, with host name datastore1.vlab.iu.hio.no, that should not be called a cluster.

    But if I want to run your script, I should offer you a cluster name. So, what is the name of the cluster here?

    Thank you.

    Hello

    If you're referring to the createResourcePool.pl script, the documentation provides an example on how to use the vSphere SDK for Perl script.

    ./createResourcepool.pl--serveur reflex.primp - industries.com - username primp - cluster "R & D" - resourcepool rp6

    You will need to provide the name of the vCenter cluster where you want to create the pool of resources, in the example I created a pool of resources called "rp6" to the title of the group 'R & D'.

    If you are just to handle a crowd of ESX (i) autonomous which looks like you are, then you will need some modification of the script to allow you to create a pool of resources directly on the host ESX (i). Attached is a quick tweak to the script existing and all what you need to do is to connect directly to your host and specify the name of the list of resources you want to create. It assumes that there is no existing resource pool and this will be attached to the main world 'resourcePool' which is there by default, but you don't see it.

    Here's the syntax:

    . /RP.pl - Server himalaya.primp - industries.com - username root resourcepool - myRP

  • Satellite A100-234: how to identify the good recovery CD

    I have 20 laptops from TOSHIBA in my office. I have the CD of restoration for all laptops kept together. Now I want to reinstall my laptop A100-234.

    How do I identify the recovery for this laptop CD.

    I tried to use 3 different recovery CD. With all the CD Installation is done properly and reboot is requested. But the system does not start.

    Any suggestions?

    Generally all recovery CD are labeled and you should see the name of the laptop on the recovery CD.
    In order to compare the information on the CD with the numbers that lie at the bootom of the laptop.

Maybe you are looking for

  • Novice user! Must remove HD and reinstall snow leopard please

    I have an old Power Mac with my old stuff and that you don't remember the passwords. I want to remove the full HD and re-install Snow leopard (I have the original disks) how do I do this please.

  • Satellite Pro U500 - download to activate the built in webcam?

    My apologies if this is the wrong forum, but I'm a new user here. can someone direct me to a link to the download to activate the built in webcam on my satellite pro u500 please? Thanks to all in advance marchamjack

  • HP pavilion n209tx 15: 10 without recovery window decommissioning

    I installed the technical preview of window 10 without window recovery 8.1. but now I want to go to the previous window of version 8.1

  • Acer aspire switch v10 wifi problem.

    Hello I'm sorry if this has been asked before but I looked and that you can not see this problem. My friend got an Acer Aspire switch V10 from the EA Store with mobile internet, but want to connect Wifi too when shes at home. The problem is that ther

  • EA6500 ping <>5.0 GHz 2.4 GHz wifi?

    How to ping at 2.4 GHz WiFi from the 5.0 GHz WiFI devices devices? Switch EA6500 WiFI, I have a few on 5.0 GHz and other devices on 2.4 GHz wifi. PC WiFi 5.0 GHz have access to the internet (such as PCs on 2.4 GHz WiFi), but they do not have ping PCs