Update openquery remote table with join

Hi All,
I have a problem with OPENQUERY update on remote table. I've googled for days, and can't solve the problem.
Here is the problem:
Local server MS SQL 2005.
Remote server: MySQL.
The linked server is communicating through MySQL ODBC 5.1
I created the following code for update (tried many other version too, this is the last one):
update openquery(Remoteserver,'select products_id, products_price, products_last_modified, products_stock from products1')
set
products_price=A.products_price,
products_stock=A.products_stock,
products_last_modified=getdate()
FROM
(select * from vi_products_update) AS A INNER JOIN
openquery(octopus, 'select products_id from products1')AS B
ON A.products_id=B.products_id
When I run the query the columns are updated with the same value, for each record. It looks the value is the first which match the criteria. Each (remote and local) table has as primary key products_id. In this example I used as result set for local a view, but I have the same result if I use a table.
the products_last_modified column is updated in order, and if I update for e.g. the products_price with a constant that is ok too. The problem should be somewhere with join, but I can' get it where.
THX for any help
ab

Hi
Did you ever solve this problem
I have the same issue trying to update many rown in a MySQL table from SQL2005 using the syntax below,
UPDATE
openquery(DEV,'select id, `desc` from todLocationGroups')
SET [desc] = V.Destination_Group FROM
(select * from VTM_TOD_Rate) as V inner join
openquery(DEV,'select id, `desc` from todLocationGroups') as K
ON K.id = V.TOD_LG_ID
but i get this error
OLE DB provider "MSDASQL" for linked server "KAYOTE_DEV" returned message "Row cannot be located for updating. Some values may have been changed since it was last read.".
Msg 7343, Level 16, State 4, Line 1
The OLE DB provider "MSDASQL" for linked server "KAYOTE_DEV" could not UPDATE table "[MSDASQL]". The rowset was using optimistic concurrency and the value of a column has been changed after the containing row was last fetched or resynchronized.

Similar Messages

  • Can't update a sql-table with a space

    Hello,
    In a transaktion I'm getting some Values from a SAP-ERP System via JCO.
    I update a sql-table with this values with a sql-query command.
    But sometimes the values I get from SAP-ERP are empty (space) and I'm not able to update the sql-table because of a null-value exception. (The column doesn't allow null-values). It seems that MII thinks null and space are the same.
    I tried to something like this when passing the value to the sql-query parameter but it didn't work:
    stringif( Repeater_Result.Output{/item/SCHGT} == "X", "X", " ")
    stringif( Repeater_Result.Output{/item/SCHGT} == "X", "X", " ")
    this works but I don't want to have a "_"
    stringif( Repeater_Result.Output{/item/SCHGT} == "X", "X", "_")
    Any suggestions?
    thank you.
    Matthias

    The problem is Oracle doesn't know the space function. But it knows a similar function: NVL --> replaces a null value with something else. So this statement works fine for me:
    update marc set
    LGort = '[Param.3]',
    dispo = '[Param.4]',
    schgt = NVL('[Param.5]', ' '),
    dismm = '[Param.6]',
    sobsl = NVL('[Param.7]',' '),
    fevor = '[Param.8]'
    where matnr = '[Param.1]' and werks = '[Param.2]'
    If Param.5 or Param.7 is null Oracle replaces it with a space in every other case it is the parameter itself.
    Christian, thank you for your hint with the space function. So I remembered the NVL-function.
    Regards
    Matthias

  • In OWB I need to update the target table with same field for match/update

    In OWb I am trying to update the target table with the match and the update on the same field can this be done. I am getting a error match merge error saying you cannot update and match on the same field. But in SQl my select is
    Update table
    set irf = 0
    where irf = 1
    and process_id = 'TEST'
    Hwo do i do this in OWB.

    table name is temp
    fields in the table
    field1 number
    field2 varchar2(10)
    field3 date
    values in the table are example
    0,'TEST',05/29/2009
    9,'TEST',05/29/2009
    0,'TEST1',03/01/2009
    1,'TEST1',03/01/2009
    In the above example I need to update the first row field1 to 1.
    Update temp
    set field1 = 1
    where field1 = 0
    and field2 = 'TEST'
    when I run this I just need one row to be updated and it should look like this below
    1,'TEST',05/29/2009
    9,'TEST',05/29/2009
    0,'TEST1',03/01/2009
    1,'TEST1',03/01/2009
    But when I run my mapping I am getting the rows like below the second row with 9 also is getting updated to 1.
    1,'TEST',05/29/2009
    1,'TEST',05/29/2009
    0,'TEST1',03/01/2009
    1,'TEST1',03/01/2009

  • Updating an oracle table with data from an xml string

    Hi - I need help with the following problem:
    We have a table in the database with a field of xml type. We are going to take each string that gets inserted into the xml type field in the 'xml table' and parse the data into another oracle table with corresponding fields for every element.
    once the record gets inserted into the 'real table' the user might want to update this record they will then insert another record into the 'xml table' indicating an update(with a flag) and then we need to update the 'real table' with the updated values that have been sent in.
    The problem that I am having is that I do not know how to create this update statement that will tell me which fields of the table need to be updated.(only the fields that need to be updated will be in the xml string in the 'xml table').
    Please help me with this - ASAP!

    Are you wanting to upload the file through an Oracle Form or just upload a file? If it isn't via forms, then you should probably post your question here: {forum:id=732}
    You also should post the version of Forms, Database, etc...
    As far as uploading files via a text file, I personally like to use Oracle External Tables even in Forms. You can Google that and there is plenty of information. If you search this forum, then you will see lots of people use UTL_FILE in forms, but you can Google that also for more information.

  • Why updates on some tables with always on synchronize mode take * 100 than when asynchronize mode

    I have Always-On synchronization on some databases, We want to change from asynchronize mode to synchronize mode, I tested to see what the  change in performance between the two, and found that in general the select statements keep the same
    duration with and without synchronize mode, most of the update\insert usually take around * 4 times from the asynchronize mode, BUT some updates take much longer. I would like to understand why things take MUCH longer (I understand that working with synchronize
    mode is a 2 phase commit and should take * 4 times, but I can't understand why some of them take 50 - 100 times more).
    1. One query is an update made on a table with few records (up to 40 records), this update run 250K times a day, and a very simple update on this table takes * 98 than without synchronize mode
    1. An update on a big table with 2 million records, using a query that specify the unique column in the primary cluster key, takes 50 times more.
    What are  the factors that have dramatic influence on performance when 2 phase commit (asynchronize mode) is used?

    I've never even looked at the details for SQL Server, but on any kind of a system doing synchronous updates, you have to figure there is a fixed cost, a variable cost, and a queuing cost.  The fixed cost always hits whether its a big transaction or
    a small transaction, let's guess it's about 0.1 seconds for a round trip.  Variable cost depends on how much is updated, let's say it's linear, and is maybe 0.05 seconds for a couple of small rows.  The queuing cost varies from 0 to huge.
    So if you have a small transaction on a local system that takes 0.05 seconds (50 milliseconds), then just one will incur the local 0.05, plus 0.10, plus 0.05, and zero queuing cost, so 0.05 -> 0.20, about 4x.
    But if you have something that runs 250k times a day I hope it's faster, maybe it's only 0.01 seconds locally, and that turns to 0.01 + 0.10 + 0.01 + q, so 0.01 -> 0.12+q, so it's at *least* 12x slower, and maybe if you get 100 of them
    in the same second you start incurring queuing delays also, in fact you may have similar queuing delays on the local system and remote system besides any communications queuing, but if just the synchronization system has some queuing limits and it even gets
    to 0.30 seconds then 0.01 -> 0.42, or 42x, and you start seeing what can happen.  If your local transaction is only 0.001 seconds when not synchronized, then you'd have 100x slowdown just on the fixed overhead!
    IOW, synchronized systems and tons of small, fast transactions just don't fit together very well.
    HTH,
    Josh

  • Need to update column in table from joining the two tables

    Hi
    i want to update a table by joining two table but i m getting the below error
    single row subquery returns more than one value.
    i m using following query
    update table2
    set deposite_date=(select a.deposit_date from table1 a,table2 b
    where a.ban=b.ban and (a.deposit_date between b.cy_start_date and b.due_date))
    table2
    ban due_date cy_start_date deposite_date
    100 5/6/2011 22/05/2011
    101 7/11/2011 22/05/2011
    102 5/25/2011 22/05/2011
    table1
    ban      deposit_date
    100      04/12/2011
    100      04/15/2011
    102      03/25/2011
    101      04/26/2011
    101      05/06/2011
    101      07/26/2011
    can i insert latest deposit_date from table1 which lies between b.cy_start_date and b.due_date
    Thanks

    Hi,
    Welcome to the forum!
    876466 wrote:
    Hi
    i want to update a table by joining two table but i m getting the below error
    single row subquery returns more than one value.Exactly!
    (   SELECT  a.deposit_date
        FROM    ...returns all deposit_dates.
    (   SELECT  MAX (a.deposit_date)
        FROM    ...would return only the latest one.
    Also, you need to correlate the sub-query to the main query, so that it only looks for rows with the same ban.
    i m using following query
    update table2
    set deposite_date=(select a.deposit_date from table1 a,table2 b
    where a.ban=b.ban and (a.deposit_date between b.cy_start_date and b.due_date))
    table2
    ban due_date cy_start_date deposite_date
    100 5/6/2011 22/05/2011
    101 7/11/2011 22/05/2011
    102 5/25/2011 22/05/2011
    table1
    ban      deposit_date
    100      04/12/2011
    100      04/15/2011
    102      03/25/2011
    101      04/26/2011
    101      05/06/2011
    101      07/26/2011
    can i insert latest deposit_date from table1 which lies between b.cy_start_date and b.due_datePerhaps you need something like this:
    UPDATE  table2     b
    SET     deposit_date     =
             (    SELECT  MAX (a.deposit_date)
                   FROM      table1           a
               WHERE      a.ban          = b.ban
               AND      a.deposit_date BETWEEN b.cy_start_date
                               AND     b.due_date
    ;Notice that table1 is the only table in the FROM clause of the sub-query, but the sub-query is correlated to table2, so we can reference columns from table2 in the sub-query.
    Whenever you have a problem, post CREATE TABLE and INSERT statements for your sample data.
    Also post the results you want from that data, and an explanation of how you get those results from that data, with specific examples.
    If you're asking about a DML statement, such as UPDATE, the CREATE TABLE and INSERT statements should re-create the tables as they are before the DML, and the results will be the contents of the changed table(s) when everything is finished.
    Always say which version of Oracle you're using.
    Edited by: Frank Kulash on Aug 1, 2011 1:58 PM

  • Update the database table with the content of the internal table

    Hello!
      I have the next form:
      FORM erase_data.
    SELECT * FROM zadrress INTO CORRESPONDING FIELDS OF TABLE itab_adrress.
      DELETE TABLE itab_adrress: FROM zadrress,
                                 WITH TABLE KEY adrid = '456'.
      WRITE 'The information after the DELETE operation'
      COLOR 2.
      LOOP AT itab_adrress INTO wa_adrress .
        WRITE:/
               wa_adrress-adrid COLOR 5,
               wa_adrress-name COLOR 7,
               wa_adrress-email COLOR 5,
               wa_adrress-depart COLOR 7,
               wa_adrress-display COLOR 5.
      ENDLOOP.
      SKIP.
    LOOP AT itab_adrress INTO wa_adrress.
       MODIFY zadrress FROM wa_adrress.
       COMMIT WORK.
       IF sy-subrc = 0.
         WRITE 'OK !'.
         SKIP.
       ELSE.
         WRITE 'FAIL !'.
         SKIP.
       ENDIF.
    ENDLOOP.
      MODIFY zadrress FROM TABLE itab_adrress.
      UPDATE zadrress FROM TABLE itab_adrress.
    TRANSPORTING adrid, name, email, depart, display.
    INSERT zadrress FROM TABLE itab_adrress ACCEPTING DUPLICATE KEYS.
    PERFORM display_data .
    ENDFORM.                    "erase_data
    I see that my record is deleted  when I display the records from my internal table, but
    now I want to delete the record from database table.
       For that I want to move the content of the modified internal table in the database table. You can see the methods I tried (some of them commented), but nothing seems to work.
    Any advice ?
    Thank you.

    FORM erase_data.
    SELECT * FROM zadrress INTO CORRESPONDING FIELDS OF TABLE itab_adrress.
    DELETE TABLE itab_adrress: FROM zadrress,
    WITH TABLE KEY adrid = '456'.
    WRITE 'The information after the DELETE operation'
    COLOR 2.
    LOOP AT itab_adrress INTO wa_adrress .
    WRITE:/
    wa_adrress-adrid COLOR 5,
    wa_adrress-name COLOR 7,
    wa_adrress-email COLOR 5,
    wa_adrress-depart COLOR 7,
    wa_adrress-display COLOR 5.
    ENDLOOP.
    SKIP.
    LOOP AT itab_adrress INTO wa_adrress.
    MODIFY zadrress FROM wa_adrress.
    COMMIT WORK.
    IF sy-subrc = 0.
    WRITE 'OK !'.
    SKIP.
    ELSE.
    WRITE 'FAIL !'.
    SKIP.
    ENDIF.
    ENDLOOP.
    <b>DELETE FROM zadrress.</b>  "Make this change and try
    MODIFY zadrress FROM TABLE itab_adrress.
    UPDATE zadrress FROM TABLE itab_adrress.
    TRANSPORTING adrid, name, email, depart, display.
    INSERT zadrress FROM TABLE itab_adrress ACCEPTING DUPLICATE KEYS.
    PERFORM display_data .
    ENDFORM. "erase_data'.

  • Insertion into local table from remote table with contains clause

    Hi all,
    We are tasked to insert some rows into our database from another database. We tried to use DBLinks to link the 2 databases and were able to use Select statements to filter out the data that we need to insert into our database.
    These statements take the form of: Select * from RemoteTable where contains@RemoteLink(IndexColumn, 'car')>0;
    where RemoteLink is the DBLink that we have created.
    However Oracle gave us an error (ORA-00949: illegal reference to remote table) when we tried to insert the dataset from the above statement into our local table. We used the following statement in doing so: Insert Into LocalTable (Select * from RemoteTable where contains@RemoteLink(IndexColumn, 'car')>0);
    Even if we use Create Table, Oracle gave us the same error when we tried to push the data from the Select Statement into the new table.
    Could anyone advise us whether it is possible to insert such data into a local table? And if som what is the proper way of doing it?
    Many thanks to any advises.

    Hi,
    there is document 261741.1 on Metalink. This states explicitly that it is not possible to invoke remote user-defined operators, and contains is such. The solution given in the article is to create a wrapper function on the remote site and this one calling in stead of contains.
    Herald ten Dam
    htendam.wordpress.com

  • How to reduce time when updating table with join of anther table

    Hi all,
    I am update table Policy1 using another table from other scheme
    Policy1 is in schema "TEST".
    TRN_POLICY_RISK_GIS is in Schema "TEST2".
    Now i am executing my query which is taking lot of time to update and make cpu utilization upto 45%.
    update policy1 set total_si = (select total_is from (select pol_sys_id,
    avg(nvl(pol_cvr_si,0)) total_si from TEST2.TRN_POLICY_COVER_GIS tpcg
    group by pol_sys_id ) b where p.pol_sys_id = b.pol_sys_id)
    Help to optimize to given query.

    update policy1    A
        set total_si =
           (select avg(nvl(pol_cvr_si,0))
               from TEST2.TRN_POLICY_COVER_GIS    B
              where B.pol_sys_id = A.pol_sys_id
    ;hopefully there is an index on TEST2.TRN_POLICY_COVER_GIS (POL_SYS_ID)

  • Updating a table with data from another table with joins involving 3 other

    update party_relship pr
    set pr.COMMENT_TEXT = temp.notes
    from party p,
    party p1,
    party_reference pref,
    TEMP_DEPT_NOTE temp
    where pr.FROM_PARTY_ID = p.PARTY_ID
    and p.CMA_CUSTOMER_NUMBER = temp.cma_num
    and pr.TO_PARTY_ID = p1.PARTY_ID
    and p1.PARTY_ID = pref.PARTY_ID
    and pref.REFERENCE_VALUE = temp.deptnum
    ORA-00933: SQL command not properly ended
    What is the problem here.
    Thanks !

    There are a few issues here 1) no from clause is directly part of the update stmt,
    2) temp.notes is not available directly
    I am not 100% sure this update is correct since I am selecting temp.notes using the same query as the in the where clause but I wanted to show the complete syntax. Basically if you need to limit the number of updates done then change the select that is part of the exists clause, if you need to change the way the pr.comment_text is being set then to need to change the sub_query.
    update party_relship pr
    set pr.comment_text =
                     (select temp.notes
                      from   party p,
                             party p1,
                             party_reference pref,
                             temp_dept_note temp
                      where  pr.from_party_id = p.party_id
                      and    p.cma_customer_number = temp.cma_num
                      and    pr.to_party_id = p1.party_id
                      and    p1.party_id = pref.party_id
                      and    pref.reference_value = temp.deptnum)
    where  exists(select 1
                  from   party p,
                         party p1,
                         party_reference pref,
                         temp_dept_note temp
                  where  pr.from_party_id = p.party_id
                  and    p.cma_customer_number = temp.cma_num
                  and    pr.to_party_id = p1.party_id
                  and    p1.party_id = pref.party_id
                  and    pref.reference_value = temp.deptnum)Message was edited by:
    Bob C

  • Ncache, MemCache, and SQL Server tables With Joins

    Hello,
    I'd like to look into a caching solution which could not only store results of a query, but also the table structures to do joins on the caching layer eliminating the need to do it on the SQL Server side.  Essentially I want to cache the customers table
    and orders table so the look ups are done on the caching software, does anyone know of a good solution for this?
    Support my SQL MCM & Internal Training blog on AliRazeghi.Com.  Have a tough I.T. job and you need to talk to someone with no obligation?  Contact my certified
    associates and I at Rosonco.com!
    If you find a question answered please click 'mark as answer' or 'vote as helpful'.  This will help other users find answers quickly.  Thanks for visiting!

    Just to get an update on microsoft SQL Server caching solutions - what are they and where can we learn more about them?  

  • Updating a DB table with only non-empty values of a work area

    Hi everybody,
    Is that possible in ABAP to update a table in the database with a work area, but only with non-empty values of this work area?
    Example:
    data: ls_custom type ZCUSTOMERS_0.
    ls_custom-CUSTOMER = '20'.
    ls_custom-LASTNAME = 'MyName'.
    ls_custom-FIRSTNAME = ' '.
    ls_custom-CURRENCY = ' '.
    update ZCUSTOMERS_0 from ls_custom.  *" I want that the update clause don't do the update with FIRSTNAME  and CURRENCY fields because they have empty values*
    If it's possible, how to do it?
    Thanks & regards,
    Abdel

    Total Questions:  81 (66 unresolved)
    Hi,
    To my understanding you mean if the database table has values
    customer         20
    lastname          somename
    firstname         firstname
    currency          INR
    so now after this
    data: ls_custom type ZCUSTOMERS_0.
    ls_custom-CUSTOMER = '20'.
    ls_custom-LASTNAME = 'MyName'.
    ls_custom-FIRSTNAME = ' '.
    ls_custom-CURRENCY = ' '.
    update ZCUSTOMERS_0 from ls_custom.
    you want the result as
    customer         20
    lastname          Myname
    firstname         firstname
    currency          INR
    Is it so? Then Normal update
    data: ls_custom type ZCUSTOMERS_0.
    ls_custom-CUSTOMER = '20'.
    ls_custom-LASTNAME = 'MyName'.
    update ZCUSTOMERS_0 from ls_custom.
    would do that.
    Thanks,
    Sri.

  • Update a "point" table with the poly_id the point belongs to

    Sorry, I'm re-posting this message as I initially included in my previous question!
    Hi,
    Dan, thanks for your help on "improving performance in loading spatial data" question.
    Yes, after droping the spatial index it worked much quicker!
    Now I have another problem with the table I've managed to populate at a decent speed (with your help!)
    There is a column, poly_id which is the polygon the point belongs to. There is another table that stores all the polygons.
    I tried the following PL/SQL code but again, it takes ages to run, regardless of having the table indexed or not.
    So the tables are
    Measurements - unit_id, start_time,relative_time,meas_point,meas_type,dv_id,poly_id
    and
    areas - poly_id,poly_name,polygon,layer
    And the code is
    PROCEDURE upd_meas
    IS
    CURSOR pos_cur IS
    SELECT * FROM measurements;
    BEGIN
    FOR pos_rec IN pos_cur LOOP
    UPDATE measurements SET poly_id = (select poly_id from areas a WHERE layer='MAR'
    and mdsys.sdo_filter(a.polygon,pos_rec.meas_point,'querytype=WINDOW' ) = 'TRUE'
    and rownum =1)
    WHERE relative_time=pos_rec.relative_time
    AND meas_type=pos_rec.meas_type
    AND unit_id=pos_rec.unit_id;
    COMMIT;
    END LOOP;
    END;
    Any hint on how to improve the performance? I've also tried sdo_relate without any difference in the execution time.
    With thanks in advance,
    Silvia

    Hi Silvia,
    Is there an index on the layer column in the areas table? If so, you may want to use the noindex hint
    so it doesn't get used instead of the spatial index. For more info on hints check the Oracle doc for
    Designing an Tuning for Performance.
    I would use SQL*PLUS to prototype getting a fast response from a filter or relate call (only - not in the context
    of the update statement), then use that syntax in spatial portion of the pl/sql update statement.
    The spatial portion of the query to test might look something like this:
    select /*+NO_INDEX(a layer_idx_name) */  poly_id from areas a WHERE layer='MAR'
    and mdsys.sdo_filter(a.polygon,pos_rec.meas_point,'querytype=WINDOW' ) = 'TRUE'
    and rownum =1;
    or
    select /*+ index (a polygon_spatial_idx_name) */...
    Hope this helps,
    Dan

  • Error ORA-01446 when updating a versioned table with SQLDeveloper 1.5.4

    Hi,
    I have been trying out Oracle Workspace Manager to test how versioned tables might work to our advantage. My basic testing process is:
    1. Create a table
    2. Add some data rows
    3. Version enable the table
    4. Create a workspace
    5. Goto the created workspace
    6. Update a row
    7. Commit and I get the following error
    UPDATE "COMSERV"."A_OWM_TEST" SET DESCRIPTION = 'ABCDEFGHIJzzzz' WHERE ROWID = 'AAAThNAAIAAAgwqAAY'
    One error saving changes to table "COMSERV"."A_OWM_TEST":
    Row 10: ORA-01446: cannot select ROWID from view with DISTINCT, GROUP BY, etc.
    The same update works fine from SQLPlus so my question is Does SQL developer support table versioning or have I done something wrong is setting up my versioned tables?
    Any suggestions greatly appreciated.
    Thanks
    Richard Wilkinson

    hye...
    is that any view referring to that table...
    check the code on how u create that view...
    for e.g.
    CREATE OR REPLACE VIEW testview
    (id, name)
    AS
    select * from testing;
    this also will populate that ORA-01446 error.
    just a suggestion cause i also have a similar problem on ORA-01446 and i resolve it by alter the view..
    CREATE OR REPLACE VIEW testview
    (id, name)
    AS
    select id, name from testing;
    correct me if i'm worng...i'm just a newbie..
    thank you...

  • ORA-01747 when updating a remote table

    Hi,
    Here is my table :
    SQL> desc infolig2.pylone_type
    Nom NULL ? Type
    PYL_CODE_PYLONE NOT NULL VARCHAR2(32)
    OPY_CODE NOT NULL VARCHAR2(32)
    NPY_CODE NOT NULL VARCHAR2(32)
    PYL_TENS_CONS VARCHAR2(32)
    PYL_NB_TERNE FLOAT(126)
    PYL_HAUT_TOTAL FLOAT(126)
    PYL_HAUT_SS_CONS FLOAT(126)
    PYL_POIDS FLOAT(126)
    PYL_SURFACE_SOL FLOAT(126)
    PYL_SURFACE_PEINTE FLOAT(126)
    PYL_DATE_CREAT NOT NULL DATE
    PYL_DATE_MODIF DATE
    PYL_TYPE_MODIF VARCHAR2(1)
    PYL_CODE_UTIL VARCHAR2(20)
    PYL_DESIGNATION VARCHAR2(50)
    PYL_ETAT VARCHAR2(15)
    PYL_INDICE_REV VARCHAR2(3)
    I need to update it from a remote database.
    So, I run the following procedure :
    set serveroutput on
    declare
    GET_DESIGNATION VARCHAR2(10) := 'AUVERGNE';
    OIP_PYL_CODE_PYLONE VARCHAR2(32) := 'TEST1';
    OIP_OPY_CODE VARCHAR2(32) := 'ORIG3';
    OIP_NPY_CODE VARCHAR2(32) := 'NATPYL2';
    OIP_PYL_TENS_CONS VARCHAR2(32) := null;
    OIP_PYL_NB_TERNE FLOAT := 1;
    OIP_PYL_HAUT_TOTAL FLOAT := null;
    OIP_PYL_HAUT_SS_CONS FLOAT := null;
    OIP_PYL_POIDS FLOAT := null;
    OIP_PYL_SURFACE_SOL FLOAT := null;
    OIP_PYL_SURFACE_PEINTE FLOAT := null;
    OIP_PYL_DATE_CREAT DATE := SYSDATE;
    OIP_PYL_DATE_MODIF DATE := SYSDATE;
    OIP_PYL_TYPE_MODIF VARCHAR2(1) := 'M';
    OIP_PYL_CODE_UTIL VARCHAR2(20) := 'RTE REFERENCE';
    OIP_PYL_DESIGNATION VARCHAR2(50) := 'TEST 1';
    OIP_PYL_ETAT VARCHAR2(15) := 'interdit';
    OIP_PYL_INDICE_REV VARCHAR2(3) := '23';
    OIP_PYL_CODE_PYLONE_SUBST VARCHAR2(32) := 'CODEPYL5';
    begin
    execute immediate 'UPDATE infolig2.PYLONE_TYPE@'||GET_DESIGNATION||' SET
    PYL_CODE_PYLONE = :1,
    OPY_CODE = :2,
    NPY_CODE = :3,
    PYL_TENS_CONS = :4,
    PYL_NB_TERNE = :5,
    PYL_HAUT_TOTAL = :6,
    PYL_HAUT_SS_CONS = :7,
    PYL_POIDS = :8,
    PYL_SURFACE_SOL = :9,
    PYL_SURFACE_PEINTE = :10,
    PYL_DATE_CREAT = :11,
    PYL_DATE_MODIF = :12,
    PYL_TYPE_MODIF = :13,
    PYL_CODE_UTIL = :14,
    PYL_DESIGNATION = :15,
    PYL_ETAT = :16,
    PYL_INDICE_REV = :17,
    WHERE PYL_CODE_PYLONE = :18'
    USING OIP_PYL_CODE_PYLONE,OIP_OPY_CODE,OIP_NPY_CODE,OIP_PYL_TENS_CONS,OIP_PYL_NB_TERNE,OIP_PYL_HAUT_TOTAL,OIP_PYL_HAUT_SS_CONS,OIP_PYL_POIDS,OIP_PYL_SURFACE_SOL,OIP_PYL_SURFACE_PEINTE,OIP_PYL_DATE_CREAT,OIP_PYL_DATE_MODIF,OIP_PYL_TYPE_MODIF,OIP_PYL_CODE_UTIL,OIP_PYL_DESIGNATION,
    upper(translate(OIP_PYL_ETAT,'éè','ee')),OIP_PYL_INDICE_REV, OIP_PYL_CODE_PYLONE_SUBST;
    exception
    when others then
    dbms_output.put_line('ERREUR ORACLE DETECTEE ***');
    dbms_output.put_line('Message Erreur : '||SUBSTR(SQLERRM,1,245));
    end;
    I receive the error :
    ORA-01747: invalid user.table.column, table.column, or columns specification
    What is the problem ?
    Regards,
    Rachel

    This reply was very useful for me. I have written insert scripts in the package where I had put comma after last_updated_date in the insert statement, I got the error -
    ORA-01747: invalid user.table.column, table.column, or column specification . After removing the comma and adding right parenthesis it worked fine
    INSERT INTO CPT_ACTIVITY_SALES (
    WS_DATE,
    ACTIVITY,
    WS_ITEM_HEAD,
    WS_FLAG,
    CREATED_BY,
    CREATED_DATE,
    LAST_UPDATED_BY,
    LAST_UPDATED_DATE,
    (SELECT a.ws_date,
    b.activity,
    C.WS_ITEM_HEAD,
    'N',
    cUser ,
    SYSDATE,
    cUser,
    SYSDATE
    FROM CPT_SALES_LINES a,cpm_category b,CPM_ACTIVITY C
    WHERE a.COMPANY=nCompany
    AND a.SITE=ln_site
    AND a.WS_DATE=ld_ws_date
    AND a.SALES_HEADER_KEY=ln_Sales_header_key
    and B.company=A.company
    and b.category_id=a.category_id
    AND C.COMPANY=A.COMPANY
    AND C.ACTIVITY=B.ACTIVITY)

Maybe you are looking for

  • How to compare performance of 2 reports which update a database table?

    I have got this assignment of optimizing the perfomance of an existing report. I made a report zreport_2 & executed both of them in background simultaneously to compare the time. However, the following error was reported during the concurrent run: Ex

  • How do I change iTunes store?

    This is going to sound like a really simple question but it isn't.....How do I change from the French iTunes store to the UK store? Normally one just logs onto iTunes and selects the country from the Modify Payment/Region menu puts in the payment det

  • MIGO - Posted lines can appear more than once

    Hi Gurus, when posting inb. dlvs. with MIGO, sometimes we get some of the lines posted multiple times, I guess we've understood the reason why but we're still looking for a solution (instead of saying to the user "leave the transaction and get back i

  • Unable to call one number from prepaid phone

    >MODERATOR COMMENT:  The follow is a post from kentman5. It has been moved from an obscure location to here for better exposure. Dear Tech Support, I am unable to dial xxx-xxx-xxxx from my verizon pre paid phone number of xxx-xxx-xxxx. I have used *7

  • Classic FDM 11.1.2.3  :  getting error while importing data : internet explorer can not display the webpage

    hello All, we are on EPM 11.1.2.3.500. when FDM client user click on import from workflow in FDM , for some time it shows processing then they get following error. when user gets log off and then log in then they found gold fish for import. so it mea