How to upgrade a table which contains 100,000 lines?

Hi all!
I see that I was wrong with column form (GRAG table), namely Gtype: 3003

(MDSYS. SDO_GEOMETRY (3003,50632625, 'null', MDSYS. SDO_ELEM_INFO_ARRAY (1,5,1,1,2,1), MDSYS. SDO_ORDINATE_ARRAY(276.2339,-179.7433,0,276.2498,-179.7361, 0))

And I need to update the Gtype value: 3003 to 3002.
My problem is that I don't know how to implement because the table GRAG has 30000 rows. I can't update the each line manually.

Do you have any advice?

As much as I KNOW oracle11g can simply update SDO_GEOMETRY.

This means creating new SDO_GEOMETRY with old values.

try to change this option (I wrote once to circumvent the cannot not change the SDO_GEOMETRY problem):

--------------------------------------------------------
-geometry of the clones but with different values
-We can "change" the SRID
-Note: oracle 11g cannot change the geometries
--------------------------------------------------------
function alter_geometry (p_geo sdo_geometry, p_srid number default null)
sdo_geometry is back
v_result sdo_geometry;
number of v_srid;
Start
If p_srid is null then
v_srid: = p_geo. SDO_SRID;
on the other
v_srid: = p_srid;
end if;
v_result: = sdo_geometry (p_geo. SDO_GTYPE,
v_srid,
p_geo. SDO_POINT_TYPE,
p_geo. ANSDO_ELEM_INFO,
p_geo. SDO_ORDINATES);
Return v_result;
end alter_geometry;

--

-and then do an update as
-before test with a table to create in select
Update crack c set c.shape = alter_geometry (shape,...)

Tags: Database

Similar Questions

  • How to upgrade a table which includes nearly 1 Million Records

    Hello

    Take the base for our Referenece emp table and allows to assume that it contains about 60000 Records and all the deptno in this table are out of 10. Please allow an update statement that would update the deptno column in the table EMP ((according to) order by EMPNO) in each increment of 1 120 reviews. (DeptNo to be incremented by 1, 10, 11, 12, etc.).

    First 120 deptno records should be 10,
    Then 120 deptno records should be 11 and so on.
    .
    .
    .
    .
    .
    .
    For the last 120 deptno records should be updated with 500.

    Please notify.

    Kind regards

    OK, I did it on a more limited set, incrementing each 5 folders...

    SQL> ed
    Wrote file afiedt.buf
    
      1  update emp2 set deptno = (select newdeptno
      2                            from (select empno, 10+floor((row_number() over (order by empno)-1)/5) as newdeptno
      3                                  from emp2
      4                                 ) e2
      5                            where e2.empno = emp2.empno
      6*                          )
    SQL> /
    
    14 rows updated.
    
    SQL> select * from emp2;
    
         EMPNO ENAME      JOB              MGR HIREDATE                    SAL       COMM     DEPTNO
    ---------- ---------- --------- ---------- -------------------- ---------- ---------- ----------
          7369 SMITH      CLERK           7902 17-DEC-1980 00:00:00        800                    10
          7499 ALLEN      SALESMAN        7698 20-FEB-1981 00:00:00       1600        300         10
          7521 WARD       SALESMAN        7698 22-FEB-1981 00:00:00       1250        500         10
          7566 JONES      MANAGER         7839 02-APR-1981 00:00:00       2975                    10
          7654 MARTIN     SALESMAN        7698 28-SEP-1981 00:00:00       1250       1400         10
          7698 BLAKE      MANAGER         7839 01-MAY-1981 00:00:00       2850                    11
          7782 CLARK      MANAGER         7839 09-JUN-1981 00:00:00       2450                    11
          7788 SCOTT      ANALYST         7566 19-APR-1987 00:00:00       3000                    11
          7839 KING       PRESIDENT            17-NOV-1981 00:00:00       5000                    11
          7844 TURNER     SALESMAN        7698 08-SEP-1981 00:00:00       1500          0         11
          7876 ADAMS      CLERK           7788 23-MAY-1987 00:00:00       1100                    12
          7900 JAMES      CLERK           7698 03-DEC-1981 00:00:00        950                    12
          7902 FORD       ANALYST         7566 03-DEC-1981 00:00:00       3000                    12
          7934 MILLER     CLERK           7782 23-JAN-1982 00:00:00       1300                    12
    
    14 rows selected.
    

    but the principle would be the same.

  • List of PT TABLES, which contain the digital certificate

    Team,

    We have set up free sign certicate in our environment.

    So, can someone share the list of the PT TABLES, which contain the digital certificate.

    Because, we do not have to refresh the environment and I don't want to lose the digital certificate after the update.

    Thank you

    Take a look at the following.  I did something similar in refresh scripts

    • PSCERTDB - raw certificate data
    • PSCERTDEFN - certificates
    • PSCERTDEFNDEL - certificates delete record.
    • PSCERTISSUER - the issuer of the certificate
  • 5.6.1 pages: How to create a table with more than 999 lines?

    5.6.1 pages: How to create a table with more than 999 lines?

    The table on Pages v5.6.1 line selector is limited 3-digit, as it is in Pages ' 09 v4.3. Either use LibreOffice Writer, who does not have any constraint line on processing tables 3-digit, or any application spreadsheet for top 3-digit row needs.

  • How to upgrade an ESXi host from the command line

    Sorry for bumping an old thread. I'm new to ESXi. I'm under ESXi 5.5 build 1331820 and I am at a loss how to apply patches.

    Preferably, I would like to apply all the relevant patches through console (SSH). Can someone give me pointers how to do this? Thank you

    Moderator note (a.p.): branched to a new discussion of software patch to version 1331820?

    Welcome to the community,

    on how to patch a ESXi host from the command line, please see for example http://kb.vmware.com/kb/2008939

    Basically download you the latest hotfix package and install it using the command esxcli . That said, please make sure that your hardware is supported by the patch that you want to apply (see http://www.vmware.com/go/hcl). You can also do before installing the patch, is to do a "dry - run" to know what . VIBS are removed and which are installed by the patch. To do this add -dry - run to the esxcli command line.

    In the case where something goes wrong, you can revert to the previous state by pressing SHIFT-R , while the ESXi hosts begins the start-up.

    André

  • What is the right way to commit 100,000 lines?

    Hi guys and girls,

    With the help of JDev 11.1.2.3.0.

    I have 10 000 ranks of the master, gave each of them runs in 9 different algorithms, 90 000 detail lines.  I now need to commit the 100,000 (10 000 masters & 90 000 retail) lines to my database.  What is the best way to accomplish this feat?  I am open to suggestions and ideas.  I'm not married to a particular approach, any strategy and have little experience running such a large DataSet.

    Currently, I iterate through the lines view object 10 000 in my application and for each line module, apply a Prediction algorithm, whose results are inserted into an object of the detail view.  The main line of vo is updated with a reference for the best results in detail, and then all have been committed through getDbTransaction.commit ();

    Is there a way to say, commit 10 000 lines, let the database do its thing and once again the calculations?  Once the database did commit, commit an another 10,000.  In this way the module of the application and the database work in parallel rather than one waiting on the other.

    Thoughts?

    Thank you

    Will be

    It looks like that there. Check the Advanced Techniques of object entity - 11 g Release 1 (11.1.1.7.0)

    As far as I know, there is no parallel work (adf and db). What you can do is to use the PL/SQL to insert the data and calculations on the side of the db. This can be faster than to browse all lines in the adf.

    Timo

  • How to upgrade a table column using the values in the Oracle collection

    create or replace procedure test_coll
    
    IS
    
    CURSOR upd 
    IS
    SELECT CONTACT_NAME FROM Supplier_16;
    
    TYPE dept IS TABLE OF upd%rowtype;
    cur_var dept;
    
    Type List Is table Of  varchar2(20);
    Name List:=  List('Shilpi','Sunil','Shreyas','Saral');
    
    BEGIN
    
    OPEN upd;
    LOOP
         FETCH upd BULK COLLECT INTO cur_var;
    --    EXIT WHEN upd%NOTFOUND;
    
         FORALL i IN cur_var.FIRST..cur_var.LAST
      
         UPDATE supplier_16
    **  SET Contact_name= name(i);  ***
         
         COMMIT;
    
    END LOOP;
    CLOSE upd;
    
    END;
    On the "BOLD" line, I don't know how I should move the values of the collection of name I said without which are set all the values in the table supplier_16 = 'Saral.

    Help, please.

    Aashish S. wrote:
    Thank you very much...

    Yes, I slide collections and was trying to reach somwthing on similar lines to which you provided the code example...

    My essay is equipped to take a collection: initialized with values of say 3-4...

    Take other tables... A column... and update the column in the table (not PK, FK anything) using the values of the initialized collection...

    However, I am stuck between the two on how the UPDATE clause should be...

    OK, if it's just because you want to practice with collections, you might do something like this...

    SQL> set serverout on
    SQL> create table supplier_16 as
      2  select 'Frederick' as contact_name from dual union all
      3  select 'Robert' from dual union all
      4  select 'Jeremy' from dual union all
      5  select 'Simon' from dual
      6  /
    
    Table created.
    
    SQL> create or replace procedure test_coll is
      2    CURSOR upd IS
      3      SELECT CONTACT_NAME
      4      FROM Supplier_16
      5      FOR UPDATE;
      6    Type List Is table Of  varchar2(20);
      7    Name List := List('Shilpi','Sunil','Shreyas','Saral');
      8    v_contact_name varchar2(30);
      9    v_idx          number := 1;
     10  BEGIN
     11    OPEN upd;
     12    LOOP
     13       FETCH upd INTO v_contact_name;
     14       EXIT WHEN upd%NOTFOUND;
     15       UPDATE supplier_16
     16       SET    contact_name = name(v_idx)
     17       WHERE CURRENT OF upd;
     18       DBMS_OUTPUT.PUT_LINE(v_contact_name||' update to '||name(v_idx));
     19       v_idx := v_idx + 1;
     20    END LOOP;
     21    CLOSE upd;
     22    COMMIT;
     23  END;
     24  /
    
    Procedure created.
    
    SQL> exec test_coll;
    Frederick update to Shilpi
    Robert update to Sunil
    Jeremy update to Shreyas
    Simon update to Saral
    
    PL/SQL procedure successfully completed.
    
    SQL> select * from supplier_16;
    
    CONTACT_N
    ---------
    Shilpi
    Sunil
    Shreyas
    Saral
    

    Of course, there is treatment rank by rank and is not best for performance, but it allows you to access your collection that you created names.

  • How to upgrade a table after each iteration?

    Hello

    I have a vi which works fine but the problem is that it updates all the data once the vi stops running. I want something as soon as (for outside for loop) 1 iteration it performs updates the table in front of the Panel, then 2nd iteration, it updates again and so on. Can anyone help me please with this.

    Thank you

    In fact, in your case, there are a simpler way to do it... If we talk about the pink channel on the first loop indicator.

    Just move the table from outside the loop inside the loop indicator.

  • How to upgrade the table based on data in multiple tables?

    TABLE1:

    =======

    TXN_ID | NAME

    --------------------

    TX001 | null

    TX002 | null

    TX003 | null

    TX004 | null

    TX005 | null

    TX006 | null

    TX007 | null

    TX008 | null

    TX009 | null

    TABLE2

    ========

    TXN_ID

    -------

    TX002

    TX004

    TX005

    TX006

    TABLE 3

    ========

    TXN_ID

    -------

    TX001

    TX008

    TX009

    If TABLE1. TXN_ID present in TABLE2, I should update the form ABC TABLE1.NAME.

    If TABLE1. TXN_ID present in table 3, I should update TABLE1.NAME as XYZ.

    I can update this by running 2 scripts.

    UPDATE TABLE1 SET B.SID = 'ABC' WHERE

    IT EXISTS (SELECT 1 FROM TABLE2 B WHERE B.TXN_ID = A.TXN_ID);

    UPDATE TABLE1 SET B.SID = "XYZ" WHERE

    IT EXISTS (SELECT 1 FROM TABLE 3 C WHERE C.TXN_ID = A.TXN_ID);

    How can we do this in a single script? I have more than 10 tables as TABLE2 and TABLE3.

    Output should be:

    TABLE1:

    =======

    TXN_ID | NAME

    --------------------

    TX001 | XYZ

    TX002 | ABC

    TX003 | null

    TX004 | ABC

    TX005 | ABC

    TX006 | ABC

    TX007 | null

    TX008 | XYZ

    TX009 | XYZ

    Assuming a table2 and table3 will not have same tnx_id you can do.

    merge into table1 t1

    a_l'_aide_de)

    Select txn_id

    name

    de)

    Select txn_id, "TABLE2" name

    from table2

    Union of all the

    Select txn_id, name "TABLE3."

    table 3

    )

    ) t2

    on)

    T1.txn_id = t2.txn_id

    )

    When matched then

    set t1.name, t2.name = update

  • How to upgrade a table within a trigger

    I have a simple question.
    Suppose I have the table TAB1 with fields F1 and F2 and I created the following trigger;

    create or replace trigger insert_TAB1
    After Insert on TAB1
    for each line
    declare

    Tab1 v_F2. % Of F2 type;

    Start

    ...
    ...
    v_F2: =...;
    ...
    ...

    Update TAB1
    the F2 value = v_F2
    where F1 =: old. F1;

    end;

    If I try to insert a record into TAB1, I get:

    ERROR on line 1:
    ORA-04091: table tab1 is changing, function of triggering/can not see
    ORA-06512: at "INSERT_TAB1", line 47
    ORA-04088: error during execution of trigger 'INSERT_TAB1 '.

    Can you help me?
    What I want is to write a trigger that inserts a value into a field after that insert was performed in the table.

    Thank you!

    Hello

    Thank you for this.

    The trigger can be written like this

    create or replace trigger insert_TAB1
    before insert on TAB1
    for each row when(new.F1 is not null)
    begin
    :new.F2=..;
    end;
    

    see you soon

    VT

  • How to create a table with spaces between the lines...

    Hello

    I use jdev 11.1.1.6 and I need to insert spaces between the lines. How this can be done?

    Thank you and best regards,
    Tarun Agrawal

    Hello

    I'm sorry to forget on the spacer. You must use css like mentioned AP.

    Arun-

  • How to upgrade a folio AppStore published and on-line?

    Hello world!!! I have a live multi folio in the AppStore now, but it has some errors in ortohraphy? So I need to republish the same folio with spelling changes simple! Can you help me please who is the best and simplest please! ??? It's our first live folio but he needs a few small changes! Im a beginner Please I need help as soon as posible! Everyone?

    1st - you update the indesign file.

    2. you select section of the folio in the Panel of the Folio Builder idesign (Menu-> Windows-> Folio Builder), then updated in the top right menu. At this point, you can use Adobe Content Viewer iPad app (get for free on the AppStore) to test your folio updated (the one with the square of blue lighting bolt). Log in with id Viewer that your application uses for Acrobat from Adobe content server.

    3. you go to the top up to the level of folio to Folio Builder idesign Panel and then select producer Folio in the upper right of the Panel. This will bring producer Folio in the web browser.

    4 Select the portfolio you want to update and click the blue "Update" button on the right. This updates the folio on the Distribution of DPS Service. Please note: this is different from the Acrobat content server.

    Documents: Digital Publishing Suite help | Folios of publication for the Distribution Service

  • How to create a table with editable column values.

    Hello world
    I think it's very simple, but I am unable to find how to do this. This is my requirement. I need to create a table with n columns and 1 line initially. the user must be able to enter data into this table and click of a button must insert the data into the database table. Also, there should be a button at the bottom of the table to add 1 line to the table.

    I know how to do the insertion of data, but can someone please let me know how to create a table which allows the user to enter data and how to create a line button Add 1?


    Thanks in advance!

    Raghu,

    Go through the tutorial of Toolbox Page & Advanced section of the Guide of the OFA table.

    Step 1 - you need to create EO & VO from this EO. This EO will be table of database where you want to insert the data.

    Step 2 - create an advanced table region. (See this section in table advanced for more details)

    Step 3 - attach this VO in the BC4J region advanced Table component.

    Kind regards
    GYAN

  • IB: how to upgrade a serial number which performs hardware inventory operations?

    Dear friends

    first of all thank you for your time and the valid solutions

    Install the base: how to upgrade a serial number which performs hardware inventory operations


    description of the problem:

    Install the base > Quick search

    Here's the Installbase folder, when I fast search query

    REC # Item serial number State of the Instance element
    1 3000000 300-7000-01-1000XXX-0538JQ0003 of return for Exchange Adv
    2 8000000 300-7000-01-1000XXX-0538JQ0003-return for Exchange Adv
    3 300 - 7000-01 5000000 1000XXX-0538JQ0003-A return for Exchange Adv


    looking over the data, first recordings and the third are legitimate serial numbers (correct to the customer's specifications), second record is not legitimate because it has a dashboard as a suffix, we found there are several illegitimate serial numbers exist, must be updated with the right of the serial numbers which I analyzed in great after having pulled data from mtl_material_transactions oe_order_lines_all, mtl_serial_numbers, mtl_system_items_b
    Basically, these are all RMA

    I need to update the second album under the name 1094SUZ-0538JQ0003-B by the guidelines, updating, I need to keep all the existing contracts, warranty, what ever material operations, there need to be same.

    We have a package to update serial numbers using the IB (csi_Item_Instance_Pub.update_item_instance) API, but it updates only the records which has no current serial number of this instance, if there is a serial number already exists, it does not work.

    user to define the error msg ' serial number 1094SUZ-0538JQ0003-a inventory of significant transactions. " This serial number cannot be used to update an existing Instance of point", but I need to update anyway! or am I missing something here, please advice me

    post below resembles similar question, talking about hard update, I have no idea, by the practice that the serial number update will have same operations, contracts and dates... attached to it as previous serial number

    IB UPDATE_ITEM_INSTANCE ERROR - does not allow ACTIVE_START_DATE change


    would be great if you guys help me, really appreciated!


    Unfortunately, I could not find any solution in metalink for the existing serial number update


    Code to update the serial number using the IB API
    x_msg_count: = 0;
    x_msg_data: = ";
    p_instance_rec.INSTANCE_ID: = rec.child_instance_id;
    p_instance_rec.Serial_number: = rec.child_serial_number;
    p_instance_rec.object_version_number: = rec.child_object_number;
    p_txn_rec.transaction_id: = Fnd_Api.g_miss_num;
    p_txn_rec.transaction_date: = SYSDATE;
    p_txn_rec.source_transaction_date: = SYSDATE;
    p_txn_rec.transaction_type_id: = 1;

    csi_Item_Instance_Pub.update_item_instance
    (
    p_api_version = > 1.0,
    p_commit = > Fnd_Api.g_false,
    p_init_msg_list = > Fnd_Api.g_false,
    p_validation_level = > 1,
    p_instance_rec = > p_instance_rec,
    p_ext_attrib_values_tbl = > p_ext_attrib_values_tbl,
    p_party_tbl = > p_party_tbl,
    p_account_tbl = > p_account_tbl,
    p_pricing_attrib_tbl = > p_pricing_attrib_tbl,
    p_org_assignments_tbl = > p_org_assignments_tbl,
    p_asset_assignment_tbl = > p_asset_assignment_tbl,
    p_txn_rec = > p_txn_rec,
    x_instance_id_lst = > x_instance_id_lst,
    x_return_status = > x_return_status,
    x_msg_count = > x_msg_count,
    x_msg_data = > x_msg_data
    );


    Thank you
    Suri

    Suri
    This used. Is perhaps not perfect, but you should get there. Only if the table is saved (all tables seeded should be registered) it will work.

    Select a.table_name, distinct b.column_name from fnd_tables a, fnd_columns b
    where a.table_id = b.table_id
    and upper (b.column_name) like ' % SERIAL.

    Also it is a very old, but if you need history for this change adds logic to insert story as well...

    DECLARE
    l_return_err VARCHAR2 (80);

    PROCEDURE debug (p_message IN VARCHAR2)
    IS
    BEGIN
    dbms_output.put_line (SUBSTR (p_message, 1, 255));
    END debugging;
    BEGIN
    debug('======================================================================');
    debug ("switching of serial number XDT07406. to XDT07406');
    debug('======================================================================');

    UPDATE fa_additions_b
    Serial_number SET = "XDT07406."
    WHERE Serial_number = 'XDT07406.';
    debug (' number of rows in fa_additions_b :'|| update) SQL % number of lines);

    UPDATE fa_mass_additions
    Serial_number SET = "XDT07406."
    WHERE Serial_number = 'XDT07406.';
    debug (' number of rows in fa_mass_additions :'|| update) SQL % number of lines);

    UPDATE rcv_serial_transactions
    Serial_num who SET = "XDT07406."
    WHERE the serial_num which = "XDT07406.";
    debug (' number of rows in rcv_serial_transactions :'|| update) SQL % number of lines);

    UPDATE mtl_serial_numbers
    Serial_number SET = "XDT07406."
    WHERE Serial_number = 'XDT07406.';
    debug (' number of rows in mtl_serial_numbers :'|| update) SQL % number of lines);

    UPDATE mtl_unit_transactions
    Serial_number SET = "XDT07406."
    WHERE Serial_number = 'XDT07406.';
    debug (' number of rows in mtl_unit_transactions :'|| update) SQL % number of lines);

    UPDATE csi_item_instances_h
    SET new_serial_number = "XDT07406".
    WHERE new_serial_number = 'XDT07406.';
    debug (' number of rows in csi_item_instances_h :'|| update) SQL % number of lines);

    UPDATE csi_t_txn_line_details
    Serial_number SET = "XDT07406."
    WHERE Serial_number = 'XDT07406.';
    debug (' number of rows in csi_t_txn_line_details :'|| update) SQL % number of lines);

    UPDATE csi_item_instances
    Serial_number SET = "XDT07406."
    WHERE Serial_number = 'XDT07406.';
    debug (' number of rows in csi_item_instances :'|| update) SQL % number of lines);

    UPDATE wsh_delivery_details
    Serial_number SET = "XDT07406."
    WHERE Serial_number = 'XDT07406.';
    debug (' number of rows in wsh_delivery_details :'|| update) SQL % number of lines);

    debug('======================================================================');
    debug ("switching of serial number jct20591 to JCT20591'");
    debug('======================================================================');

    UPDATE fa_additions_b
    Serial_number SET = "JCT20591."
    WHERE Serial_number = "jct20591";
    debug (' number of rows in fa_additions_b :'|| update) SQL % number of lines);

    UPDATE fa_mass_additions
    Serial_number SET = "JCT20591."
    WHERE Serial_number = "jct20591";
    debug (' number of rows in fa_mass_additions :'|| update) SQL % number of lines);

    UPDATE rcv_serial_transactions
    Serial_num who SET = "JCT20591."
    WHERE the serial_num which = "jct20591";
    debug (' number of rows in rcv_serial_transactions :'|| update) SQL % number of lines);

    UPDATE mtl_serial_numbers
    Serial_number SET = "JCT20591."
    WHERE Serial_number = "jct20591";
    debug (' number of rows in mtl_serial_numbers :'|| update) SQL % number of lines);

    UPDATE mtl_unit_transactions
    Serial_number SET = "JCT20591."
    WHERE Serial_number = "jct20591";
    debug (' number of rows in mtl_unit_transactions :'|| update) SQL % number of lines);

    UPDATE csi_item_instances_h
    SET new_serial_number = "JCT20591".
    WHERE new_serial_number = 'jct20591 ';
    debug (' number of rows in csi_item_instances_h :'|| update) SQL % number of lines);

    UPDATE csi_t_txn_line_details
    Serial_number SET = "JCT20591."
    WHERE Serial_number = "jct20591";
    debug (' number of rows in csi_t_txn_line_details :'|| update) SQL % number of lines);

    UPDATE csi_item_instances
    Serial_number SET = "JCT20591."
    WHERE Serial_number = "jct20591";
    debug (' number of rows in csi_item_instances :'|| update) SQL % number of lines);

    COMMIT;
    EXCEPTION
    WHILE OTHERS
    THEN
    l_return_err: = "update in one of Scripture has this error :'|| substrb (sqlerrm, 1, 55);
    debug ("l_return_err value ='|") l_return_err);
    END;
    /

    Thank you
    Claire

  • How to upgrade a selection one line of the table based on values in another table when there is exactly one matching entry and negligence if there is more than a football game

    Hello

    I'm trying to achieve the following objectives:

    1. in table A, select rows based on the values in column 2. something like SELECT * FROM TABLE A WHERE (COLUMN2 = 'X' or Column2 IS NULL)

    2 and these values selected, I want to update Column3 from Table A if TableA.column1 = TableB.column1, but only if there is exactly one game. If there are multiple matches, column 3 of the table article updated.

    That's what I've tried so far.

    UPDATE TABLE_A

    SET

    TABLE_A.COLUMN3 = (SELECT COLUMN3 OF TABLE_B

    WHERE ((TABLE_B.COLUMN1 = TABLE_A.COLUMN1) AND ( TABLE_B.COLUMN1 IN (SELECT Column1 FROM TABLE_B GROUP BY COLUMN1 , HAVING COUNT (*) = 1)))

    WHERE EXISTS (SELECT * FROM TABLE_A)

    WHERE ((TABLE_A.COLUMN2 = 'X' OU TABLE_A.COLUMN2 = 'Y') AND (TABLE_A.COLUMN4 IS NULL OR TABLE_A.COLUMN4 = ' ')));

    More details on my DB environment:

    Version Info:

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

    PL/SQL Release 11.2.0.4.0 - Production

    Toad, but, depending on whether the query updated all lines. I would really appreciate if someone could tell me how to fix my request.

    Thanks in advance.

    Exists it predicate in the block of update will be set to true if there is at least one row in table_a where column2 is X or Y and column4 is null or a space. You need to correlate exists it with the outer query query (I'm guessing on column1) to get the result I think you want.  However, who would update all rows in table_a who meets the criteria, there is a corresponding row in table_b, affecting Column3 lines form null not matched or not.  (Again), I'm guessing that's not your intention.  If you only want to update the lines in table_a which have a corresponding line in table_b and meet the other predicate, then I think you want something more like:

    Update table_a

    Set table_a.column3 = (select column3 of table_b

    where table_b.column1 = table_a.column1 and

    Table_B.Column1 in (select column1 from table_b

    Group by column1, having count (*) = 1))

    where ((table_a.column2 = 'X' ou))

    table_a.Column2 = 'Y') and

    (table_a.column4 is null or)

    table_a.column4 = ' ')) and

    table_a.Column1 in (select column1 from table_b

    Group by column1, having count (*) = 1)

    John

Maybe you are looking for

  • Wake up to Pandora on cannot try first?

    I recently bought the Sony Dash and noticed when I set my alarm to wake up to Pandora, I get a beep instead of Pandora, but if I hit snooze then Pandora will play, it seems that Pandora doesn't load fast enough for the first alarm is anyway to remedy

  • can I create a link google to Windows Live Mail

    can I link my google calendar and contact list of contacts and the calendar in Windows Live Mail? My windows Live ID is my google e-mail address if it matters.

  • My recovery from Windows Live Hotmail email is more so, how do I change my password?

    My recovery from hotmail email is no more so, how do I change my password etc... I can't even change my email recoverry because it will send a confirmation to the old enamel.

  • Why can't enroll in ms explorer?

    I have an older xp when I sign in my box and password give I get it cannot connect due to no ms Messenger.  I had already downloaded the ms messenger... There may be a conflict between the Herald and the exploer or third party?    any help would be g

  • Issue of dialogue

    Hello I use the following code to the user: Dialog d = new Dialog("Select Level",new String[] {"Level 1","Level 2","Level 3"},new int[]{0,1,2},0,Bitmap.getPredefinedBitmap(Bitmap.QUESTION)); d.doModal(); int result = d.getSelectedValue(); ... But whe