Creating a correct trigger condition

hi All,
I have a problem in my trigger condition in my query.
The background:
1. I have a List view with a Data insertion (Lead Select) into a ROW.
2. Also, I have 5 different queries which are triggered based on a selection of a Radio button.
Now, my req is that Query1 should load either on
                                                         change of Lead select in List View
                                                   OR if the chosen Radio button is 1
Query2 should load either on
                                                         change of Lead select in List View
                                                   OR if the chosen Radio button is 2
& so on.
Can you please help me with a valid trigger condition. ? The concatenate is not working as the Xcel only allows Value Change or Value Becomes.
Currently, I am launching all the 6 queries at once using CONCATENATE + VALUE CHANGE. This is a huge hit on performance.
Cheers
Kiran

What if you have 5 different cells (one for each query) and you only have the trigger cell for Query 1 show the list select value only if the chosen radio button is 1 and so on?
Formula for Query 1 Trigger Cell: =If(=1,,"")
Formula for Query 2 Trigger Cell: =If(=2,,"")
~~~~~~~~~~~~~~~
Formula for Query 5 Trigger Cell: =If(=5,,"")
Then, the value in any given cell should update any time the radio button is changed (from "" to the ListSelectValue) and anytime the ListSelect value changes (assuming that radio button is selected).

Similar Messages

  • How to send e-mail when a trigger condition is verified?

    Hi,
    I want to implement a trigger to send an e-mail when the condition of the tigger is verified.
    Thanks in advance.
    Paulo.

    i'm using the sample code you can find at http://otn.oracle.com/sample_code/tech/pl_sql/htdocs/Utl_Smtp_Sample.html to implement the mail function.
    Check out you gateway configuration cause i had some problems with it at the beginning
    my trigger goes like this (i use it to receive a mail everytime i have a exception in one of my processes):
    create or replace trigger TRG_error_handle
    after insert on errores
    for each row
    begin
    demo_mail.mail(sender => "sendername", recipients => "your emailadress",
    subject => 'Error en reporte ' || :new.proceso,
    message => 'Ha ingresado un error de aplicación a las ' ||
    to_char(:new.fecha, 'hh24:mi:ss') || ' del ' ||
    to_char(:new.fecha, 'dd/mm/yyyy') || chr(13) ||
    ' Proceso: ' || :new.proceso || chr(13) ||
    ' Mensaje de error: ' || :new.err_desc);
    end if;
    end TRG_error_handle;
    Good luck.-

  • Trigger condition for IDOC

    Hi,
    I have trigger condition for IDOC
    All materials where:
    "Finished Goods"  Technical Names MARA-MTART = "Z001", and the Plants are "Granollers" MARC-WERKS="ES11", MARC-WERKS="ES12", goods that are "ready" or "ready for manufacturing", MARC-MMSTA = "02" or "03".
    All the materials which satisfy this criteria will need to be triggered whenever a new material is created in SAP which meets the above criteria, or if any materials are modified which meet the above criteria in SAP.
    How do I trigger my IDOC based on these conditions.
    Regards,
    Subhashini

    Hi,
    Please create the Idoc type / segments , create message type and link Idoc and message.
    Steps to customize a new IDoc >>>
    1. Define IDoc Segment (WE31)
    2. Convert Segments into an IDoc type (WE30)
    3. Create a Message Type (WE81)
    4. Create valid Combination of Message & IDoc type(WE82)
    5. Define Processing Code(WE41 for OUT / WE42 for IN)
    6. Define Partner Profile(WE20)
    2. Yes, you need LS & Partner profile
    3. Yes use MASTER_IDOC_DISTRIBUTE
    4. Can use IDOC_CREATE_ON_DATABASE instead of MASTER_IDOC_DISTRIBUTE and then process the Idoc.
    Message Type :: The message type defines the semantic context of an IDoc. The message type tells the processing routines, how the message has to be interpreted. The same IDoc data can be sent with different message types.
    IDoc Type :: An IDoc type defines the syntax of the IDoc data. It tells which segments are found in an Idoc and what fields the segments are made of.
    Processing Code :: The processing code is a logical name that determines the processing routine. This points usually to a function module, but the processing routine can also be a workflow or an event.
    The use of a logical processing code makes it easy to modify the processing routine for a series of partner profiles at once.
    Partner profile :: Every sender-receiver relationship needs a profile defined. This one determines
    The processing code
    The processing times and conditions
    In the case of outbound IDoc 1. The media port used to send the IDoc and 2. Triggers used to send the IDoc
    Partner Type :: The IDoc partners are classified in logical groups. Such as : LS, KU, LI.
    LS - Logical Systems : It is meant to be a different computer and was primarily introduced for use with the ALE functionality.
    KU - Customer : The partner type customer is used in classical EDI transmission to designate a partner, that requires a service from your company or is in the role of a debtor with respect to your company, e.g. the payer, sold-to-party, ship-to-party.
    LI - Supplier : The partner type supplier is used in classical EDI transmission to designate a partner, that delivers a service to your company.
    thanks & Regards,
    ShreeMohan

  • Error while creating a simple trigger in Oracle8i Lite

    Hi,
    I have Oracle8i Lite release 4.0.
    I want to create a simple trigger on 8i Lite.
    first I created .java file and got the .class file after successful compilation.
    The .class file is sitting in my local C:\ drive.
    I have a table having only two columns in 8i Lite and the structure is
    TABLE : SP
    ACC_NO NUMBER,
    ACC_DESC VARCHAR2(20)
    Then I issued the command :
    SQL> ALTER TABLE SP ATTACH JAVA SOURCE "JournalInst" in '.';
    After that getting the following error :
    alter table sp attach java source "JournalInst" in '.'
    ERROR at line 1:
    OCA-30021: error preparing/executing SQL statement
    [POL-8028] error in calling a java method
    Following is the cause/action for the error code :
    POL-8028 Error in calling a Java method
    Cause: Most commonly refers to a problem when converting between Java and Oracle Lite datatypes.
    Action: Check the calling parameters.
    I can't understand where I am wrong ?
    Could anybody help me out ?
    Here is my source code of .java file
    import java.lang.*;
    import java.sql.*;
    class JournalInst {
    public void INSERT_JOURNAL(Connection conn, double AccNo, String AccDesc)
    System.out.println("Record Inserted for :"+AccNo +" "+AccDesc);
    Thanks in advance for solutions.
    Sarada
    null

    I just started with 8i Lite, but as far as I know 8i Lite does not support PL/SQL code.
    So you have to write your triggers and stored procedures in Java.
    Ciao

  • Error creating job into trigger using DBMS_SCHEDULER.

    Hi,
    I am trying to create job using dbms_scheduler package. I have one trigger on insert event on one table. I am creating job using following syntax.
    CREATE OR REPLACE TRIGGER TRG_BI_JOB_CONFIG BEFORE INSERT ON JOB_CONFIG FOR EACH ROW
    DECLARE
    BEGIN
         DBMS_SCHEDULER.Create_Job(job_name => 'my_job1'
                             ,job_type => 'PLSQL_BLOCK'
                             ,job_action => 'delete_temp'
                             ,start_date => TO_DATE('15-JUL-2003 1:00:00 AM', 'dd-mon-yyyy hh:mi:ss PM')
                                  ,repeat_interval => 'FREQ=DAILY'
                             ,enabled => TRUE
                             ,comments => 'DELETE FOR job schedule.');
    EXCEPTION
    WHEN OTHERS THEN RAISE;
    END;
    but I am getting following error while inserting into JOB_CONFIG table.
    ORA-04092: cannot in a trigger
    ORA-06512: at "PRAKASH1.TRG_BI_JOB_CONFIG", line 41
    ORA-04088: error during execution of trigger
    same above statement If I am running from sqlplus then It is creating job without error. If I am creating job using DBMS_JOB into trigger then It is also working fine but this package is depricated from oracle10g so I cannt use it any more.
    My Oracle version is 'Oracle DATABASE 10g RELEASE 10.2.0.1.0 - Production'.
    can anyone help me in this context.

    I have a few comments on this thread as an Oracle dbms_scheduler developer.
    - Oracle takes backward compatibility very seriously. Although dbms_job is deprecated, the interface will continue to work indefinitely. The deprecation of dbms_job is so that customers will be encouraged to take advantage of the more powerful dbms_scheduler. It is extremely unlikely that entire blocks of functionality will ever be removed. There is currently no plan to remove dbms_job functionality (and even if there were, doing so would be strenuously opposed by many users).
    - lots of internal Oracle database components are standardizing on using dbms_scheduler (resource manager, materialized views, auto sql tuning etc). This is good evidence that it will continue to be the recommended scheduling method for the foreseeable future - not even the concept of a replacement exists. It is also under active development.
    - The reason for the automatic commit is that a dbms_scheduler job is a full database object like a stored procedure or a table. So a call to dbms_scheduler.create_job is like executing a DDL which takes effect immediately. A dbms_job job is mostly just a row in a table so a call to dbms_job.submit behaves like regular DML. There are many advantages to a job being a full database object but DDL behaviour is an unfortunate requirement of this.
    Hope this clears a few things up, reply with any questions.
    -Ravi

  • Is there a way to create a corrective work order off a prevenative workore

    Hello,,
    Is there a way to create a corrective work order off a preventive/inspection work order. Or is there a way to indicate that a corrective work order was created from preventive/inspection work order. In addition is there a way to report these changes.
    Thanks.

    Yes, first take your PM WO#, and go to Transaction IW36<p>
    <p>
    This process is how to create a "sub-order"<p>
    <p>you will be asked to enter in the "superior order", in this case it will be the PM Work Order you want to be the "parent"

  • How Can i create a package/trigger

    Hi Every1,
    I want to create a database trigger which act on entering the charahters and count the characters.
    e.g
    you can understand with the example
    if i press 01 in a specific column the length of characters is two after this automatically the character sign i.e. / ( forward slash ) appers and then i can write 03 again the month and then again automatically / slash appers and i press 2009 and then go on
    then the filed will look likes 01/03/2009
    simply i dont want to press the / sign in the date fileld or place sign after ENTER through format mask property in forms 6i
    can any1 please help me
    Regards
    M. Laeeque A.

    I want to create a database trigger which act on entering the charahters and count the characters.I guess you're talking about a forms-trigger, not a database-trigger.
    if i press 01 in a specific column the length of characters is two after this automatically the character signi don't think thats possible in 6i. In 10g you could write a java-bean for that.

  • Is it possible to create a Column with Conditional Mandatory with another Column?

    Is it possible to create a Column with Conditional Mandatory with another Column?
    For example
    In a Table we have column A, B, C.
    A is Primary Column.
    B is Optional
    C is Conditional Mandatory.
    A B
    C
    12345 ABC
    OK
    12346 NULL
    NULL
    12347 ABC
    OK
    Only if the B Column has the value then only C column should be mandatory

    I guess you can't create a condtional mandatory column directly. However, you can use check constraint to on the column
    create table YourTable
      A int primary key,
      B char(3),
      C int,
      constraint ch_con check(
                                B
    is not null
    or C is null

  • Create or replace trigger

    hi i want to create trigger . when insert a row on table , it returns new value and old value . I have many tables and columns . i should to use :new.columntitle and :old.columntitle .Columntitle is refere to name of column in table . but sql developer is not accept it and show this error : BAD BIND VARIABLE 'NEW.COLUMNTITLE' .My code is this :
    Create or replace TRIGGER hr.departments_before_insert   
      before insert       on HR.departments 
       for each row
       DECLARE
          columnid number ;
         columnval number ;
         columntitle varchar2(4000);
         cursor c2 is
         select id,tableid from hr.columns where tableid = 1 ;
          tablesid number ;
          tablenames varchar2(4000);
          cursor c1 is
          select id , title from hr.tables where id = 1;
                    BEGIN
                    open c1;  
                           loop
                              fetch c1 into tablesid , tablenames;
                                  EXIT WHEN C1%NOTFOUND;    
                                   for rec in c2
                                            loop
                                                 select substr(title,instr(title,'.',-1,1)+1) into columntitle  from hr.columns where id = rec.id ;
                                                 dbms_output.put_line(:new.columntitle); -- in this line the eroor occured  : error = " bad bind variable 'new.columntitle' "
                                             end loop;
                             end loop;
                    close c1;    
                     end;
    -- in loop columntitle=deparment _id and department_name ; when i replace columntitle with department _id in :new , code is work ...
    thanks                                                                                                                                                         

    You have no choice but to specifically list the column names.
    If you really have "too many columns", that would tend to imply that you have improperly normalized your schema.  Perhaps you need to rethink the data model.
    If the real problem is that you want to generate similar triggers for a large number of different tables, you could write a PL/SQL block that generates the CREATE TRIGGER statement for each table and use EXECUTE IMMEDIATE to run those statements for each table.  Using dynamic SQL like this significantly complicates the complexity of building the trigger.  This may be balanced out, though, by the fact that you only have to write it once rather than writing separate triggers for each table.
    Justin

  • How to create a database trigger for automatic run statspack.snap

    Hi,
    I want to create a database trigger to run statspack.snap at startup.
    connect /as sysdba
    grant create any trigger to perfstat;
    connect perfstat/perfstat
    create or replace trigger auto_snap
    after startup on database
    begin
    statspack.snap;
    end;
    after startup on database
    error at line 2:
    ora-01031: insufficient privileges
    connect /as sysdba
    create or replace trigger perfstat.auto_snap
    after startup on database
    begin
    statspack.snap;
    end;
    Trigger created.
    after shutdown and startup the database, the trigger has not been run. (no statspack snapshot)
    What I have done wrong?

    981145 wrote:
    hi... I have created a database link but it is showing some error. Can you please tell me, do we have to update the details in TNSNAMES.ora file regarding the database which i am creating now before creating database link?????
    awaiting for your response,
    Thanks in advanceI'm sorry, but "showing some error" is NOT an actionable error message. Why do you think we can solve your error if you don't tell us what the error is?
    Yes you will need to adjust your tnsnames. When a process in a database_A accesses database_B via a dblink in database_A, the database_A is acting as a client to database_B. At that point database_A is just like sqlplus or sqldeveloper, and all tns considerations are the same.

  • Hi all! What is the best way to create the correct space for baseball jersey names and numbers? along with making sure they are the right size for large printing.

    What is the best way to create the correct space for baseball jersey names and numbers? along with making sure they are the right size for large printing.

    Buying more hard drive space is a very valid option, here.  Editing takes up lots of room, you should never discount the idea of adding more when you need it.
    Another possibility is exporting to MXF OP1a using the AVC-I codec.  It's not lossless, but it is Master quality.  Plus the file size is a LOT smaller, so it may suit your needs.

  • Creating a row trigger to populate the primary key

    to populate the primary key of a table automatically, i created a sequence named rule_id
    using the following statement:
    create sequence rule_id;
    and then i created a trigger to populate the primary key using the statements below:
    CREATE OR REPLACE
    TRIGGER RULE_ID BEFORE INSERT ON DOC_CATS_RULE_BASED_CLASS
    FOR EACH ROW
    BEGIN
    SELECT SEQ_RULE_BASED_CLASS.NEXTVAL
    INTO :new.id FROM DUAL;
    END;
    i took this from a books example. but it gives and error called:
    Error(3,8): PLS-00049: bad bind variable 'NEW.ID'
    What is wrong and what is the current way to do it?
    Please help!

    Hi ,
    The new denotes the new data values for the table relative column.....
    As regards the dual is a small table in the data dictionary that Oracle and user-written programs can reference to guarantee a known result. This table has one column called DUMMY and one row containing the value X.
    Regards,
    Simon

  • Create AR Correction Invoice

    Hi All,
      I need create AR Correction Invoice link to AR Invoice, abt system display error "Invalid structure document"
    oDoc = oCompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oInvoice)
    oDoc.GetByKey(XXX)
    _oOCSI = oCompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oCorrectionInvoice)
    If _oRecSet.RecordCount <> 0 Then
       _oOCSI.CardCode = oDoc.CardCode
       _oOCSI.DocDate = oDoc.DocDate
      _oOCSI.DocDueDate = oDoc.DocDate
      oOCSI.DocType = SAPbobsCOM.BoDocumentTypes.dDocumentService
      For i = 1 To _oRecSet.RecordCount
          If i > 1 Then
            _oOCSI.Lines.Add()
          End If
          oDoc.Lines.SetCurrentLine(i - 1)
          _oOCSI.Lines.BaseEntry = oDoc.DocEntry
          _oOCSI.Lines.BaseLine = oDoc.Lines.LineNum
          _oOCSI.Lines.BaseType = SAPbobsCOM.BoObjectTypes.oInvoices
          oOCSI.Lines.CorrectionInvoiceItem = SAPbobsCOM.BoCorInvItemStatus.ciisWas
          _oOCSI.Lines.Add()
           _oOCSI.Lines.BaseEntry = oDoc.DocEntry
           _oOCSI.Lines.BaseLine = oDoc.Lines.LineNum
           _oOCSI.Lines.BaseType = SAPbobsCOM.BoObjectTypes.oInvoices
          _oOCSI.Lines.LineTotal = 0
           oOCSI.Lines.CorrectionInvoiceItem = SAPbobsCOM.BoCorInvItemStatus.ciisShouldBe
          _oRecSet.MoveNext()
       Next i
       lErrCode = _oOCSI.Add
    Please Help me.

    Simply change the order of lines you are adding. First you'll have to create ShouldBe items, than the Was items.
    Dim _oOCSI As SAPbobsCOM.Documents
            _oOCSI = oCompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oCorrectionInvoice)
            _oOCSI.CardCode = "12121212212"
            _oOCSI.DocDate = Now()
            _oOCSI.DocDueDate = Now()
            _oOCSI.DocType = SAPbobsCOM.BoDocumentTypes.dDocument_Service
            _oOCSI.Lines.CorrectionInvoiceItem = SAPbobsCOM.BoCorInvItemStatus.ciis_ShouldBe
            _oOCSI.Lines.LineTotal = 0
            _oOCSI.Lines.BaseType = 13
            _oOCSI.Lines.BaseEntry = 122
            _oOCSI.Lines.BaseLine = 0
            _oOCSI.Lines.Add()
            _oOCSI.Lines.CorrectionInvoiceItem = SAPbobsCOM.BoCorInvItemStatus.ciis_Was
            _oOCSI.Lines.BaseType = 13
            _oOCSI.Lines.BaseEntry = 122
            _oOCSI.Lines.BaseLine = 0
            lErrCode = _oOCSI.Add()

  • How do I acquire waveforms in LabVIEW on multiple trigger conditions on a Tektronix TDS5000 scope? The signals are fast, so is there a way not to use a simple loop in LabVIEW?

    The signals are fast, so is there a way to acquire them without losing information? Do I have to use a loop in LabVIEW that just acquires when the trigger conditions are met?

    Hi,
    I would assume that the instrument has some sort of buffer that could store data while you are trying to download it. If this is not possible, you could use one of our DAQ cards to acquire data.
    Hope this helps.
    Best Regards,
    Aaron K.
    Application Engineer
    National Instruments

  • End-user experience during CREATE OR REPLACE TRIGGER

    Is CREATE OR REPLACE TRIGGER intended for you to be able to update a trigger in production while users are actively using a that table's data?
    Just wondering how it behaves. People currently in the middle of an event will use the old trigger, while new requests will use the new one?
    Thanks
    Chuck

    Actually, this one kind of surprised me. I tried:
    SESSION1 > DESC t
    Name                                      Null?    Type
    ID                                                 NUMBER
    DESCR                                              VARCHAR2(10)
    SESSION1 > CREATE TRIGGER t_bi
      2  BEFORE INSERT OR UPDATE ON t
      3  FOR EACH ROW
      4  BEGIN
      5     :new.descr := UPPER(:new.descr);
      6* END;
    Trigger created.Then, in anothe session I did:
    SESSION2 > INSERT INTO t VALUES (1, 'One');
    1 row created.Then in the first session:
    SESSION1 > CREATE OR REPLACE TRIGGER t_bi
      2  BEFORE INSERT OR UPDATE ON t
      3  FOR EACH ROW
      4  BEGIN
      5     :new.descr := LOWER(:new.descr);
      6* END;
    Trigger created.
    Just to prove no commit happened
    SESSION1 >SELECT * FROM t;
    no rows selectedI was expecting to see
    ORA-00054: resource busy and acquire with NOWAIT specified
    or something similar. So in session 2 I did:
    SESSION2 > COMMIT;
    Commit complete.
    SESSION2 > SELECT * FROM t;
            ID DESCR
             1 ONE
    SESSION2 > INSERT INTO t VALUES(2, 'Two');
    1 row created.
    SESSION2 > SELECT * FROM t;
            ID DESCR
             1 ONE
             2 twoSo, the new trigger is working. Now change it again:
    SESSION1 > CREATE OR REPLACE TRIGGER t_bi
      2  BEFORE INSERT OR UPDATE ON t
      3  FOR EACH ROW
      4  BEGIN
      5     :new.descr := UPPER(:new.descr);
      6  END;
      7  /
    Trigger created.and back to session 2
    SESSION2 > INSERT INTO t VALUES (3, 'Three');
    1 row created.
    SESSION2 > SELECT * FROM t;
            ID DESCR
             1 ONE
             2 two
             3 THREESo, it looks like whichever trigger is current at the time of the insertion or updation seems to control what gets in the database.
    John

Maybe you are looking for

  • Command in Bex-Analyzer

    Dear BI fans, We are now playing with the Bex-Analyzer and we try to see how much we can do to make our reports as user friendly as possible. To do this we would like to define some buttons to trigger some commands/ commands sequences². We have been

  • Tab delimitter in HeaderLine in FCC in receiver file adapter

    Hi Folks, I want to use tab as a field separator for (eg) NameA.Headerline. instead of comma in file content conversion in receiver File adapter communication channel. example: Recordset structure : NameA NameA.addHeaderLine : 3 NameA:headerLine : Ma

  • Macbook Pro keyboard and track pad freeze

    I have tried about 15 times now to post this due to the following problem Today my keyboard and track pad have suddenly frozen. In appears as if the OS is fine and running but I can't input any kind of key or cursor movement. I have to restart it. Is

  • Bug in creative cloud

    what's the point in sending you all the bug if you can't be bothered to fix it here's another one.

  • [solved]can't run java apps from command line

    Every Java program that i've tried to run from command line gives me a error message like this: augusto java% java Test Exception in thread "main" java.lang.NoClassDefFoundError: Test Caused by: java.lang.ClassNotFoundException: Test at java.net.URLC