slow performance pl/sql for insert and update (pls suggestion) required

DECLARE

TYPE IS of LOC_USI_SEQ1 TABLE customer_TABLE.customereid%type;

row_cnt number (19): = 0;

CURSOR C1 IS

SELECT customereid

OF customer_TABLE

WHERE customereid = 6316;

LOC_USI_SEQ LOC_USI_SEQ1;

BEGIN

OPEN c1;

C1 FETCH BULK COLLECT INTO LOC_USI_SEQ;

Close c1;

row_cnt: = LOC_USI_SEQ. Count;

If row_cnt = 0 THEN

INSERT INTO CUSTOMER_TABLE (CUSTOMEREID) VALUES (LOC_USI_SEQ);

ON THE OTHER

If row_cnt = 1 then

Update customer_TABLE set id = 1 where CUSTOMEREID = LOC_USI_SEQ;

INSERT INTO CUSTOMER_TABLE (CUSTOMEREID) VALUES (LOC_USI_SEQ);

on the other

If row_cnt = 2 then

Update customer_TABLE set id = 2 where CUSTOMEREID = LOC_USI_SEQ;

INSERT INTO CUSTOMER_TABLE (CUSTOMEREID) VALUES (LOC_USI_SEQ);

end if;

end if;

end if;

COMMIT;

end;

the query above works only for 1 customer id 6316. It runs in 1 sec.
But if I run for the customer id 10 lakh of input parameter,
(Whenever he runs for unique subscriber id) 10 times lachize it is running.
update by inserting the customer_table table. it becomes slow. What is the real reason behind all this?


Pls help gurus


S

Of course, it's slow.

This is the perfect example of HOW not in PL/SQL code.

Cursor fetch in PL/SQL loops are wrong 99% of the time. When you want to process the data in the database? Use SQL statements. Use SQL statements. And use SQL statements.

No PL/SQL.

Use INSERT... SELECT, MERGE, UPDATE (SELECT) and other SQL constructions.

When you want to change it manually (where you manage the treatment), run this SQL via DBMS_PARALLEL_EXECUTE.

Tags: Database

Similar Questions

  • apostrophe problem for insert and update pages

    I read in the book "Dreamweaver MX dynamic Applications" that a solution must be placed in the ASP to insert code and form fields record updated to replace the apostrophes by their equivalent html entity character (') before its entry in a database do not have SQL wrong interpret the entered text. How would you say this hotfix is essential because I tested my form with apostrophes and have not gotten into trouble yet?

    > I read in the book "Dreamweaver MX dynamic Applications" as a fix
    > should
    > place in the ASP code for insert and update the fields of the registration form to
    > replace
    > apostrophes with their equivalent html entity character (') before his
    > entry
    > in a database do not have SQL wrong interpret the entered text. How
    > Essentials
    > would you say this fix is that I tested my form with single quotes and
    > have
    > not got any trouble yet?

    If you are user of Jack and sending it to the db in plaintext in
    the query, and then people can use techniques of SQL injection basically destroy
    your database:

    http://en.Wikipedia.org/wiki/SQL_injection

    So, Yes, it's a pretty serious problem.

    -Darrel

  • Default values for Insert and Update

    What is the default way the current sysdate to a date on one column table when you perform an insert or update via a form? And related to this, what is the best way by default of the current user (APP_USER) for a varchar2 column when you perform an insert or update via a form?

    For these columns, I want to display in a report, but they must be hidden on the form, because I have the default app to sysdate and APP_USER values. However, when I tried to use the default values in table in 'the default UI settings' and using either: APP_USER or & APP_USER or SYSDATE, it shows that this literal value on the form (element is not hidden while to debug it). It does not show the actual value, I would, like "user1". Does make sense?

    Thanks for your help.
    -Reid

    I think that the triggers are the best device.

    Scott

  • Create triggers in the table, sequence, insert and update with "model"?

    It must be of rtfm, trial and error thing but you wanted to ask, is it possible to have models or similar automation for the following scenario:

    1.), I add the table to the logic model

    2.) Using glossary I transform a relational model that was recovered / synchronized with the data dictionary

    3.) then I have the new table to add

    -but

    I would then have auto-DDL of to be synchronized to database:

    -create sequence for the id column

    -create table

    -create indexes for the id column pk

    -Create triggers for insert and update

    -l' idea is to have db_created_dt and db_modified_dt defined in the table, so that each table has them to the fields of record etc.

    -activate the triggers

    Each of them following the same naming convention.

    Similarity with approx. generator Apex workshop utils sql create table of the copy paste "excel" that creates 'id' - column + sequence and insert the trigger.

    rgrds Paavo

    Hi Paavo,

    most of the steps can be made in one or other way

    -create sequence for the id column

    -create table

    -create indexes for the id column pk

    If you want to start in the logic model and you don't want to have the ID column in the logic model and select 'Create the surrogate key' checkbox in the dialog entity - you will get an identity column in the relational model and the version of database and settings in ' preferences > Data Modeler > model > physics > Oracle "you can set the sequence generation and the trigger for taking in load.

    fields of record defined in the table, so that each table has them

    You can add the same set of columns in all tables with the transformation script 'model of Table... ».

    You can also look here Oracle SQL Developer Data Modeler 4.1 user - defined DDL generation using transformation scripts

    to see how to grant your DDL generation using the transformation script. DM comes with example to generate separate tables of logging and triggers. You can create your build script of triggers that support logging in these common columns.

    Philippe

  • FORALL using insert and update

    Hello

    I want to use FORALL for insert and update at the same time in a single FORALL...

    It's like...

    FORALL INDX IN 1... record. Count
    insert into Table values (record (i)); - Table is updated with some values in the column
    Update Table
    Set table.col10 = (select val table11 where table11.column = record.count (i))
    -update the Table by taking the value of some other column table... passing the parameter each time...

    Help, please...

    Refer to this

    http://docs.Oracle.com/CD/B19306_01/AppDev.102/b14261/forall_statement.htm

    But why PL SQL?

    You can do this with the Merge statement

    http://docs.Oracle.com/CD/B19306_01/server.102/b14200/statements_9016.htm

    Mezaber

  • INSERT and UPDATE audit generating more lines expected in $ AUD

    Environment:

    Oracle 11.2.0.3 EE on Solaris

    I had a request for verification of the INSERT and UPDATE on the activities of all the tables in a particular schema. It was in anticipation of a request that will live and the owner wanted to see a 'typical' of some test users activity.

    Here are the steps I took:
    alter system set audit_trail=DB_EXTENDED scope=spfile;
    
    Bounce the instance
    
    audit INSERT table, UPDATE table by USERX;
    I also "audit_sys_operations = TRUE' so I know I'll take some SYS audit data in $ AUD as well, but I can ask around those."

    My question is that I see several connections from the application server with "LOGIN" and "LOGOUT" actions and I don't know why they are appearing in the table of AUD $.

    Is it because I have auditing enabled for inserts and updates on all THE tables for USERX and opening operations and logoff do I/O in tables that are not owned by USERX under logon logoff procedure?

    I'm a newbie audit and the docs I read not answered this question.

    I just found an article on the value of 'SESSION_REC' of ACTION_NAME and I need to change my check to "by access. I'll change that and see what happens, but it shouldn't change my question.

    Thanks much for any help!

    -gary

    Hello

    I have the SYS activities audited but I never said anything about the session auditing for this particular user.
    

    "audit session;" check all successful and failed connections to and disconnections of the database, regardless of the user, by session

    Is there a way to confirm what has been turned on for auditing?
    

    You can check with the following query

    Select * from dba_stmt_audit_opts;
    Select * from dba_priv_audit_opts;

    You can also check out the link below for more deatails
    http://psoug.org/reference/auditing.html

  • Combining insert and update to a form?

    Hello

    I am a developer web amateur who is new to dynamic Web sites, php and dreamweaver. I am currently working on a project that uses many forms to send data to a database.

    Data that are inserted must also be available to update if necessary. so I need currently 2 versions of each form 1 to insert and the other for the update.

    Is it possible to use a single form for insert and update, instead of using 2 forms 1 for each function. This would help reduce the level of duplication on the site.

    If so is anyway to do this in Dreamweaver? or could someone point me to an example of how this can be achieved.

    Thank you all

    Thanks for the information, disappointing that Dreamweaver cannot handle it, but at least I know where I am...

    Looks like that's what I need... http://forums.Adobe.com/message/1927405

    Once again thanks for your help

  • You want to capture update dates, with trigger on a view to refresh quickly materialized. But trigger on MV consider inserting and updates are inserts only.

    Oracle Database 11 g Enterprise Edition Release 11.2.0.4.0 - 64 bit Production

    PL/SQL Release 11.2.0.4.0 - Production

    CORE Production 11.2.0.4.0

    AMT for Linux: Version 11.2.0.4.0 - Production

    NLSRTL Version 11.2.0.4.0 - Production

    I create the structure of the table like that.

    create table test1 (a primary key, b (2) char number, date c, d varchar2 (10), date of e);

    create table test2 (number of ab, cd (2) tank, date of the ef, gh varchar2 (10), date of the ij, kl varchar2 (100));

    Create materialized view log on test1;

    create materialized view fast refresh test1_v on commit in select * from test1;

    I have create a trigger of the sample

    CREATE OR REPLACE TRIGGER test1_trig

    AFTER INSERT OR UPDATE OR DELETE

    ON test1_v

    FOR EACH LINE

    DECLARE

    lr_test2 test2% ROWTYPE;

    lv_error VARCHAR2 (4000);

    BEGIN

    lr_test2. AB: =: NEW.a;

    lr_test2. CD: =: NEW.b;

    lr_test2. GH: =: NEW.d;

    IF THE INSERTION

    THEN

    lr_test2. EF: = SYSDATE;

    lr_test2.IJ: = SYSDATE;

    lr_test2.KL: = 'INSERT ';

    INSERT INTO test2

    VALUES lr_test2;

    ELSIF UPDATE

    THEN

    lr_test2.IJ: = SYSDATE;

    lr_test2.KL: = 'UPDATE ';

    UPDATE test2 = lr_test2 ab WHERE = LINE: OLD.a;

    ELSIF REMOVAL

    THEN

    DELETE FROM test2

    AB = WHERE: old.a;

    END IF;

    EXCEPTION

    WHILE OTHERS

    THEN

    lv_error: = SQLERRM;

    INSERT INTO XXDOMINO_FG_DATA_LOAD_ERROR

    VALUES ('test1_trig',

    : OLD.a,.

    "test1_trig,"

    LV_ERROR,

    SYSDATE);

    COMMIT;

    END test1_trig;

    /

    So, if check you my code,.

    When I insert EF = SYSDATE, IJ = SYSDATE.

    Update EF is not changed, IJ = SYSDATE.

    So I like to capture their insertion and update dates.

    But if updates or insert arrives on the materialized table. The trigger themselves as an INSERT only.

    So how do you capture the updates?

    I use the statemnet with out merger with performance and also able to capture the update dates.

    CREATE OR REPLACE TRIGGER test1_trig_merge

    AFTER INSERT OR UPDATE OR DELETE

    ON test1_v

    FOR EACH LINE

    DECLARE

    lr_test2 test2% ROWTYPE;

    lv_error VARCHAR2 (4000);

    BEGIN

    IF THE REMOVAL

    THEN

    DELETE FROM test2

        AB = WHERE: old.a;

    ELSIF INSERTION

    THEN

    MERGE INTO test2 one

    B using (SELECT 1 FROM DUAL)

    WE (ab =: new.a)

    WHEN MATCHED

    THEN

    UPDATE the VALUE ab =: NEW.a.

    CD =: NEW.b,

    GH =: NEW.c

    IJ = SYSDATE,

    KL = "Update"

    AB WHERE =: old.a

    WHEN NOT MATCHED

    THEN

    INSERTING VALUES (: NEW.a,)

    : NEW.b,.

    : NEW.c.

    : NEW.d,.

    : NEW.e,.

    "INSERT");

    END IF;

    EXCEPTION

    WHILE OTHERS

    THEN

    lv_error: = SQLERRM;

    INSERT INTO XXDOMINO_FG_DATA_LOAD_ERROR

    VALUES ('test1_trig',

    : OLD.a,.

    "test1_trig,"

    LV_ERROR,

    SYSDATE);

    END test1_trig_merge;

    /

    DISPLAY ERRORS;

  • How to modify and update a line later was inserted and updated in the doDML() method?

    Mr President

    Jdev worm is 12.2.1

    How to modify and update a line later was inserted and updated in the doDML() method?

    I added two rows in my table a method of action-listener in bean managed and secondly with operation doDML() as below.

    Method 1-first row in managed bean

        public void addNewPurchaseVoucher(ActionEvent actionEvent) {
            // Add event code here...
            BindingContainer bindings = BindingContext.getCurrent().getCurrentBindingsEntry();        
            DCIteratorBinding dciter = (DCIteratorBinding) bindings.get("VoucherView1Iterator");        
            RowSetIterator rsi = dciter.getRowSetIterator();        
            Row lastRow = rsi.last();        
            int lastRowIndex = rsi.getRangeIndexOf(lastRow);        
            Row newRow = rsi.createRow();        
            newRow.setNewRowState(Row.STATUS_NEW);        
            rsi.insertRowAtRangeIndex(lastRowIndex +1, newRow);         
            rsi.setCurrentRow(newRow);
            
            BindingContainer bindings1 = BindingContext.getCurrent().getCurrentBindingsEntry();        
            DCIteratorBinding dciter1 = (DCIteratorBinding) bindings1.get("VdetView1Iterator");        
            RowSetIterator rsi1 = dciter1.getRowSetIterator();        
            Row lastRow1 = rsi1.last();        
            int lastRowIndex1 = rsi1.getRangeIndexOf(lastRow1);        
            Row newRow1 = rsi1.createRow();        
            newRow1.setNewRowState(Row.STATUS_NEW);        
            rsi1.insertRowAtRangeIndex(lastRowIndex1 +1, newRow1);         
            rsi1.setCurrentRow(newRow1); 
            
            
        }
    


    Method of doDML() of line 2 seconds in the entityImpl class


        protected void doDML(int operation, TransactionEvent e) {        
            setAmount(getPurqty().multiply(getUnitpurprice()));
           
            if (operation == DML_INSERT)  
                       {          
                         insertSecondRowInDatabase(getVid(),getLineitem(),getDebitst(),
        (getPurqty().multiply(getUnitpurprice()).multiply(getStaxrate())).divide(100));  
                           }
                           
                           if(operation == DML_UPDATE)
                           {
                               
                           updateSecondRowInDatabase(getVid(),getLineitem(),getDebitst(),
        (getPurqty().multiply(getUnitpurprice()).multiply(getStaxrate())).divide(100));                        
                           }                                       
            super.doDML(operation, e);
        }
    
        private void insertSecondRowInDatabase(Object value1, Object value2, Object value3, Object value4)  
                  {  
                    PreparedStatement stat = null;  
                    try  
                    {  
                      String sql = "Insert into vdet (VID,LINEITEM,DEBITST,AMOUNT) values 
       ('" + value1 + "','" + value2 + "','" + value3 + "','" + value4 + "')";  
                      System.out.println("sql= " + sql);    
                      stat = getDBTransaction().createPreparedStatement(sql, 1);  
                      stat.executeUpdate();  
                    }  
                    catch (Exception e)  
                    {  
                      e.printStackTrace();  
                    }  
                    finally  
                    {  
                      try  
                      {  
                        stat.close();  
                      }  
                      catch (Exception e)  
                      {  
                        e.printStackTrace();  
                      }  
                    }  
                  }  
                  
                  private void updateSecondRowInDatabase(Object value1, Object value2, Object value3, Object value4)  
                  {  
                    PreparedStatement stat = null;  
                    try  
                    {  
                      String sql = "update vdet set vid='"+ value1+"',lineitem='"+ value2+"',DEBITST='" 
       + value3 + "', AMOUNT='" + value4 + "' where VID='" + VID + "'";  
                      System.out.println("sql= " + sql);      
                      stat = getDBTransaction().createPreparedStatement(sql, 1);  
                      stat.executeUpdate();  
                    }  
                    catch (Exception e)  
                    {  
                      e.printStackTrace();  
                    }  
                    finally  
                    {  
                      try  
                      {  
                        stat.close();  
                      }  
                      catch (Exception e)  
                      {  
                        e.printStackTrace();  
                      }  
                    }  
                  }
    

    Now the problem is that when later I change the quantity and price of the first line isn't updated but second row, because I used the command

     <af:button actionListener="#{bindings.Commit.execute}" text="Commit"
    

    This button update the first line added by bean managed, but the second row remains unchanged.

    Please help how to update the two lines with the same button or something else.

    Concerning

    DML_UPDATE will call only if there is some change data attributes.

    I guess that the update statement is false because vid looks like a primary key for the table, then, how update you the primary key of the update statement and how the update condition statement where the vid = '0'

    I assume the update statement should look like:

      private void updateSecondRowInDatabase(Object value1, Object value2, Object value3, Object value4)
      {
        PreparedStatement stat = null;
        try
        {
          String sql =
            "update vdet set lineitem='" + value2 + "',DEBITST='" + value3 + "', AMOUNT='" + value4 +
            "' where VID='" + value1 + "'";
          System.out.println("sql= " + sql);
          stat = getDBTransaction().createPreparedStatement(sql, 1);
          stat.executeUpdate();
        }
        catch (Exception e)
        {
          e.printStackTrace();
        }
        finally
        {
          try
          {
            stat.close();
          }
          catch (Exception e)
          {
            e.printStackTrace();
          }
        }
      }
    
  • Performance 2015.4 for the InDesign update problem

    I hope this isn't a double question. I did a search on the forum and nothing has developed about the overall performance.

    I get very slow performance with InDesign 2015.4 after update from last night. When I scroll through a message at the bottom next to the preflight check, a catalog file "No error" shows "Reading [Image name]" is constantly and every time I go to another page. This happens when the GPU is enabled and disabled. And for some reason, my drop shadow details are far away. I will turn off and reapply the shadow and it looks fine until I go to another page and come back to the page with shadows and incorrectly, they reappear once again.

    I'm on an end of 2015 iMac, retina 5K

    Processor: 3.2 GHz Intel Core i5

    Memory: 8 GB 1867 MHz DDR3

    Graphics card: AMD Radeon R9 M380 2048 MB

    OS X El Capitan

    "Reading [Image name]."

    InDesign June 2015 Reading Images.jpg

    Shadow of a problem

    Drop Shadow Issue-1.jpg

    The Performance parameter of default display in ID CC 2015.4 was changed to high quality (previously it was typical by default). This setting causes the images to be displayed to their full fidelity and that's what happens when you see the 'Image of reading' at the bottom of the document window. For images in your document, it happens the first time you open a document and you go to a page containing images. Later browsing the same page (s), this does not happen because images are cached and are quickly made to high quality.

    The coordinates of the drop shadow should not change because of this setting, so cannot say why what is happening. I would like to take a look. I sent you a DM.

    Thank you

    Ravi Kiran

    Adobe InDesign team

  • Insert and update server behaviors in the same form

    I have a php form that is inserted into a table and then update another table. I have the form of inserting the record first and then I want to update the other table. I'm starting to learn and understand PHP, but I don't know how to have the update function to run after that it inserts the records. I guess that's something like if you insert this disc, then update this record and then go to the redirect page. I know this goes to redirect page after it inserts the record, but I don't know how to tell him not to go to the $insertGoTo. I want him to run the following update function and then go to the $insertGoTo and not the $updateGoTo. Thanks in advance for any help.

    if ((isset($_POST["MM_insert"])) && ($_POST["MM_insert"] == "form1")) {
      $insertSQL = sprintf("INSERT INTO employee (CompId, empfirstname, empmiddleint, emplastname, EmpType, EmpStatus) VALUES (%s, %s, %s, %s, %s, %s)",
                           GetSQLValueString($_POST['CompId'], "int"),
                           GetSQLValueString($_POST['empfirstname'], "text"),
                           GetSQLValueString($_POST['empmiddleint'], "text"),
                           GetSQLValueString($_POST['emplastname'], "text"),
                           GetSQLValueString($_POST['EmpType'], "text"),
                           GetSQLValueString($_POST['EmpStatus'], "text"));
      mysql_select_db($database_dotweb, $dotweb);
      $Result1 = mysql_query($insertSQL, $dotweb) or die(mysql_error());
      $insertGoTo = "Roster.php?CompId=" . $_POST['CompId'] . "";
      if (isset($_SERVER['QUERY_STRING'])) {
        $insertGoTo .= (strpos($insertGoTo, '?')) ? "&" : "?";
        $insertGoTo .= $_SERVER['QUERY_STRING'];
      }
      header(sprintf("Location: %s", $insertGoTo));
    }
    if ((isset($_POST["MM_update"])) && ($_POST["MM_update"] == "form1")) {
      $updateSQL = sprintf("UPDATE company SET CompanyType=%s WHERE CompId=%s",
                           GetSQLValueString($_POST['CompanyType'], "text"),
                           GetSQLValueString($_POST['CompId'], "int"));
      mysql_select_db($database_dotweb, $dotweb);
      $Result1 = mysql_query($updateSQL, $dotweb) or die(mysql_error());
      $updateGoTo = "purchases.php";
      if (isset($_SERVER['QUERY_STRING'])) {
        $updateGoTo .= (strpos($updateGoTo, '?')) ? "&" : "?";
        $updateGoTo .= $_SERVER['QUERY_STRING'];
      }
      header(sprintf("Location: %s", $updateGoTo));
      
    }
    
    

    PHP code is executed from top down and is controlled by the conditional statements ('if' blocks). To achieve what you want, you need to combine the conditional statements that control the insert and update server behaviors and to move the redirect to the end of the code. Amend as follows:

    if ((isset($_POST["MM_insert"])) && ($_POST["MM_insert"] == "form1")) {
      $insertSQL = sprintf("INSERT INTO employee (CompId, empfirstname, empmiddleint, emplastname, EmpType, EmpStatus) VALUES (%s, %s, %s, %s, %s, %s)",
                           GetSQLValueString($_POST['CompId'], "int"),
                           GetSQLValueString($_POST['empfirstname'], "text"),
                           GetSQLValueString($_POST['empmiddleint'], "text"),
                           GetSQLValueString($_POST['emplastname'], "text"),
                           GetSQLValueString($_POST['EmpType'], "text"),
                           GetSQLValueString($_POST['EmpStatus'], "text"));
      mysql_select_db($database_dotweb, $dotweb);
      $Result1 = mysql_query($insertSQL, $dotweb) or die(mysql_error());
    
      $updateSQL = sprintf("UPDATE company SET CompanyType=%s WHERE CompId=%s",
                           GetSQLValueString($_POST['CompanyType'], "text"),
                           GetSQLValueString($_POST['CompId'], "int"));
      mysql_select_db($database_dotweb, $dotweb);
      $Result1 = mysql_query($updateSQL, $dotweb) or die(mysql_error());  
    
      $insertGoTo = "Roster.php?CompId=" . $_POST['CompId'] . "";
    
      if (isset($_SERVER['QUERY_STRING'])) {
        $insertGoTo .= (strpos($insertGoTo, '?')) ? "&" : "?";
        $insertGoTo .= $_SERVER['QUERY_STRING'];
      }
      header(sprintf("Location: %s", $insertGoTo));
    }
    
  • Add error causing senior in 4.2.1 when inserting and updating same time

    Hi all

    I have problems with the top to add a line in a table.

    There is already a thread here on how to add the line above in table form in version 4.0.

    We have recently upgraded to version 4.2.1 Apex.

    Since then we have question while inserting a new line and update an existing line at the same time, and then click Save button causing the error below:

    Current version of the data in the database has changed since the user initiated the update process. version of current line identifier = "xxxxxx" line application version identifier = "xxxxxx".

    But insert a new record and update an existing record works well separately with an error.


    Here's the code to add the line at the top of page header HTML

    <script language="javascript" type="text/javascript">
    function addRowTop()
    {
    apex.widget.tabular.addRow();
    apex.jQuery(apex.widget.tabular.gTabForm).find(".highlight-row").last()
    .insertBefore(apex.jQuery(apex.widget.tabular.gTabForm).
    find(".highlight-row").first());
    }
    </script>
    

    If I use by default addRow so absolutely no problem to insert and update at the same time.

    Here is the example of work in the workspace apex.

    Looks like a bug to me.

    Can any of the Oracle team please see this and let us know if it needs a patch.

    Thank you

    REDA

    Not sure that I consider this a bug since you are somehow hacking the default functionality of the APEX.  Maybe you could add a feature request 'Add Top line' to https://apex.oracle.com/vote

    It seems that you hit some enhancments to safety that have been made to the tabular forms. You should be able to work around it by putting the new lines to the bottom of the form before submitting the page.

    Create a dynamic action based on the click of the submit button.

    Event: click on

    Selection type: button

    Button: SUBMIT (Submit)

    Condition: - no requirement.

    Add real action to run the JavaScript Code:

    Action: run the JavaScript Code

    Fire when the result of the event is: true

    Fire on Page load: [disabled]

    Code:

    apex.jQuery(apex.widget.tabular.gTabForm).find("input[value=''][name='frowid']").closest(".highlight-row")
     .insertAfter(apex.jQuery(apex.widget.tabular.gTabForm).find(".highlight-row").last());
    

    Add a real action to send the page:

    Action: send the Page

    E: Nam request/buttonSUBMIT

    -Jeff

  • Insert and update by the select statement

    Hi all
    How can I insert and update in an oracle 10g database table
    by a select statement. do not merge.

    Florian wrote:
    Hi all
    How can I insert and update in an oracle 10g database table
    by a select statement. do not merge.
    >

    How can I insert and update in a table of database oracle 10g via a select statement. do not merge.

    Do you mean by using subqueries?

    Something like

    insert into whatever
      ...select statement
    
     update whatever
        set (column, column) = (select column, column ...)
    

    There is a lot of information on this topic in the online documentation

  • How to write insert and update blocks about with an if

    Hai All

    How to write an insert and update block education about with in an if

    I had a condition Ie

    If the time is between 0630 and 1030


    then

    Insert into Daily_attend
    ----


    Update Daily_attend set

    -----

    Concerning

    Srikkanth.M

    There is nothing preventing you to do this:

    BEGIN
      INSERT INTO x (mycolumn) VALUES ('A');
    
      UPDATE x
      SET mycolumn = 'B'
      WHERE mycolumn = 'A';
    
      COMMIT;
    END;
    /
    

    other than the fact that he seems a bit inefficient. Yet once you try to do, and why, is not clear.

    Can you put an IF statement in there to choose one way or the other under certain conditions? Yes. But I wonder if what you
    are actually trying to do is to reinvent the MERGE statement.
    http://www.morganslibrary.org/reference/merge.html

  • We are in the streams we want to use the tools of replication of database of 3rd party for Oracle freeware. Pls suggest

    We are in the streams we want to use the tools of replication of database of 3rd party for Oracle freeware. Pls suggest

    Hello

    GoldenGate and shareplex are large databases for heteregenous platforms oracle replication tools.

    Shareplex replicates data between heteregenous platforms for example source on Linux and Windows.Shareplex target come from queues so that when we define it a few tables in the configuration of the source files, it will get automatically reproduced in the target database.

    SharePlex 8.6.2 technical documentation

    Concerning

    Rami

Maybe you are looking for