Merge-Operator

Hello,
I'm querying a WebService which returns a Collection of Foobar.
For each Foobar I want to query other WebServices and merge their results into the corresponding Foobar-Row.
Neither Union, nor Switch seem to be appropriate. I need something to merge the data from several ports.
Any hint how to implement this?
Thanks,
Kai

Hi Kai,
What you are describing looks similar to SQL Join functionality. There is no way to do this using Visual Composer operators.
You need to implement this in the Service layer (using CAF, EJB or any similar tool).
Regards,
   Shai

Similar Messages

  • Error in Database Adapter Insert Or Update (Merge) Operation

    I have a simple SOA composite which reads XML files and posts data to a database table using a database adapter. I would like to perform a merge operation but I keep getting this error in the log -
    SEVERE: JCABinding=> XML2DB:WriteInvToDB [ WriteInvToDB_ptt::merge(InventoryCollection) ] Could not invoke operation 'merge' against the 'Database Adapter' due to:
    BINDING.JCA-11616
    DBWriteInteractionSpec Execute Failed Exception.
    merge failed. Descriptor name: [WriteInvToDB.Inventory].
    Caused by java.lang.NullPointerException.
    Here is the complete log:
    SEVERE: JCABinding=> XML2DB:WriteInvToDB [ WriteInvToDB_ptt::merge(InventoryCollection) ] Could not invoke operation 'merge' against the 'Database Adapter' due to:
    BINDING.JCA-11616
    DBWriteInteractionSpec Execute Failed Exception.
    merge failed. Descriptor name: [WriteInvToDB.Inventory].
    Caused by java.lang.NullPointerException.
    Please see the logs for the full DBAdapter logging output prior to this exception.
    Jan 3, 2009 10:58:06 AM oracle.integration.platform.blocks.adapter.fw.log.LogManagerImpl log
    SEVERE: JCABinding=> [default/XML2DB!1.0*2008-12-23_13-27-06_078.WriteInvToDB]:merge One-way interaction failed
    Jan 3, 2009 10:58:06 AM oracle.tip.mediator.serviceEngine.MediatorServiceEngine post2Mesh
    SEVERE: Post 2 messah failed
    oracle.fabric.common.FabricInvocationException: BINDING.JCA-12563
    Exception occured when binding was invoked.
    Exception occured during invocation of JCA binding: "JCA Binding execute of Reference operation 'merge' failed due to: DBWriteInteractionSpec Execute Failed Exception.
    merge failed. Descriptor name: [WriteInvToDB.Inventory].
    Caused by java.lang.NullPointerException.
    The invoked JCA adapter raised a resource exception.
    Please examine the above error message carefully to determine a resolution.
         at oracle.integration.platform.blocks.adapter.fw.jca.cci.EndpointInteractionException.getFabricInvocationException(EndpointInteractionException.java:74)
         at oracle.integration.platform.blocks.adapter.AdapterReference.post(AdapterReference.java:226)
         at oracle.integration.platform.blocks.mesh.AsynchronousMessageHandler.doPost(AsynchronousMessageHandler.java:153)
         at oracle.integration.platform.blocks.mesh.MessageRouter.post(MessageRouter.java:152)
         at oracle.integration.platform.blocks.mesh.MeshImpl.post(MeshImpl.java:159)
         at sun.reflect.GeneratedMethodAccessor253.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:585)
    Caused by: BINDING.JCA-12563
    Exception occured when binding was invoked.
    Exception occured during invocation of JCA binding: "JCA Binding execute of Reference operation 'merge' failed due to: DBWriteInteractionSpec Execute Failed Exception.
    merge failed. Descriptor name: [WriteInvToDB.Inventory].
    Caused by java.lang.NullPointerException.
    The invoked JCA adapter raised a resource exception.
    Please examine the above error message carefully to determine a resolution.
         at oracle.integration.platform.blocks.adapter.fw.jca.cci.JCAInteractionInvoker.executeJcaInteraction(JCAInteractionInvoker.java:428)
         at oracle.integration.platform.blocks.adapter.fw.jca.cci.JCAInteractionInvoker.invokeJcaReference(JCAInteractionInvoker.java:509)
         at oracle.integration.platform.blocks.adapter.fw.jca.cci.JCAInteractionInvoker.invokeAsyncJcaReference(JCAInteractionInvoker.java:493)
         at oracle.integration.platform.blocks.adapter.fw.jca.cci.JCAEndpointInteraction.performAsynchronousInteraction(JCAEndpointInteraction.java:429)
         at oracle.integration.platform.blocks.adapter.AdapterReference.post(AdapterReference.java:193)
         ... 49 more
    Caused by: BINDING.JCA-11616
    DBWriteInteractionSpec Execute Failed Exception.
    merge failed. Descriptor name: [WriteInvToDB.Inventory].
    Caused by java.lang.NullPointerException.
    Please see the logs for the full DBAdapter logging output prior to this exception.
         at oracle.tip.adapter.db.exceptions.DBResourceException.createEISException(DBResourceException.java:488)
         at oracle.tip.adapter.db.exceptions.DBResourceException.outboundWriteException(DBResourceException.java:529)
         at oracle.tip.adapter.db.transaction.DBTransaction.commit(DBTransaction.java:287)
         at oracle.integration.platform.blocks.adapter.fw.jca.cci.JCAInteractionInvoker.executeJcaInteraction(JCAInteractionInvoker.java:311)
         ... 53 more
    Caused by: java.lang.NullPointerException
         at oracle.toplink.descriptors.DescriptorQueryManager.putCachedUpdateCalls(DescriptorQueryManager.java:1605)
         at oracle.toplink.internal.queryframework.ExpressionQueryMechanism.prepareUpdateObject(ExpressionQueryMechanism.java:1608)
         at oracle.toplink.internal.queryframework.StatementQueryMechanism.updateObject(StatementQueryMechanism.java:405)
         at oracle.toplink.internal.queryframework.DatabaseQueryMechanism.updateObjectForWriteWithChangeSet(DatabaseQueryMechanism.java:1136)
         at oracle.toplink.queryframework.UpdateObjectQuery.executeCommitWithChangeSet(UpdateObjectQuery.java:69)
         at oracle.toplink.internal.queryframework.DatabaseQueryMechanism.executeWriteWithChangeSet(DatabaseQueryMechanism.java:279)
         at oracle.toplink.queryframework.WriteObjectQuery.executeDatabaseQuery(WriteObjectQuery.java:47)
    Jan 3, 2009 10:58:06 AM oracle.integration.platform.blocks.adapter.fw.log.LogManagerImpl log
    WARNING: JCABinding=> ReadXML ReadXMLonReject: The resource adapter 'File Adapter' requested handling of a malformed inbound message. However, the following Service property has not been defined: 'rejectedMessageHandlers'. Please define it and redeploy the module. Will use the default Rejection Directory file://jca\ReadXML\rejectedMessages for now.
    Jan 3, 2009 10:58:06 AM oracle.integration.platform.blocks.adapter.fw.log.LogManagerImpl log
    WARNING: JCABinding=> ReadXML ReadXMLonReject: Sending invalid inbound message to Exception Handler:
    Jan 3, 2009 10:58:06 AM oracle.tip.mediator.common.error.ErrorMessageEnqueuer$EnqueuerThread run
    SEVERE: Failed to enqueue error message
    javax.jms.TransactionInProgressException: Cannot call commit on a XA capable JMS session.
         at oracle.j2ee.ra.jms.generic.RAUtils.make(RAUtils.java:595)
         at oracle.j2ee.ra.jms.generic.RAUtils.toTransactionInProgressException(RAUtils.java:846)
         at oracle.j2ee.ra.jms.generic.RAUtils.toTransactionInProgressException(RAUtils.java:840)
         at oracle.j2ee.ra.jms.generic.SessionWrapper.commit(SessionWrapper.java:197)
         at oracle.tip.mediator.common.error.ErrorMessageEnqueuer$EnqueuerThread.run(ErrorMessageEnqueuer.java:187)
         at java.lang.Thread.run(Thread.java:595)
    Any help is greatly appreciated.
    The INSERT operation works fine with the database adapter, but I cannot get MERGE and UPDATE operations to work as expected!
    Thanks.

    hi Sudeep,
    We are at first hand struggling with DB adapter problem getting down everytime. Don't know the reason why.
    DB adapter is in down state and when trying to make it up gives below error:
    "weblogic.application.ModuleException: weblogic.connector.exception.RAException: Jndi Name is null or empty."
    I just created a simple sync process using DB adapter (custom select) and deplyed successfully. I hope jndi name is not to be configured in weblogic-ra.xml file.
    This is the first time we are using this JNDI name (eis/DB/calvindb).
    Any inputs will be appreciated.
    Thanks,
    Nikhil

  • How to perform merge operation using Data services designer?

    I am new here and new to Data Services Desinger as well.
    And currently, I want to do a merge operation using query transform or table comparison transform. But sadly, neither one of them is giving me what I want.
    So, wonder if you could help clarify if either one of them could achieve MERGE operation between and source and target tables?
    if positive, then how?
    PS:
    by MERGE, i mean, if data exists in target table, then only do update, else, do insert. same with the standard MERGE operation of oracle.
    If you need any more info, let me know!
    Thanks in advance.

    You can do this.
    You don't need the Tabe_Comparison transform actually.
    Just query the data you need and output the flow from your query to your target table.
    Then, you'll have to check the "Auto correct load" option: this will insert new lines and updates old ones. One checked, you can ckeck the "Auto correct load" checkbox.
    By default, BODS will know a line already exists based uppon the primary key columns of your target table. If you want to change the columns used to determine if a line should be inserted or updated, use the "Use input key" checkbox (and define some PK column in your query).
    Hope this helps
    Guillaume

  • OSB JCA Merge operation for null value

    I am doing a merge and when I supply the nodes the nodes I leave empty i.e. <somenode></somenode> I expect to update, if the record exists, the database to a null, but instead it does nothing and leaves the existing value.
    Anybody know how to accomplish this, perhaps an attribute on the toplink file?

    I figured it out. You have to change the DetectOmissions="false" in the wsdl where the merge operation properties are specified.

  • DbAdapter (nolock in merge operation)

    Hello,
    I'm currently with performance problems when I do various operations on a SQL Server 2000 using a dbAdapter(merge operations).
    I did some analysis in the database and realized that I am having lock in "select" operation, and I have to wait for the "update". How can I add the command "nolock" at the end of this query?
    Thanks
    Zanatto

    Yes, this is to prevent confusion when the merge result falls outside of the active filter and is thus hidden from the user.  Sometimes it will, sometimes it won't - so we chose consistency of behavior.
    You should be able to prevent this by clicking the padlock icon in the upper right of the grid view and filter area. This will lock the filter.

  • DBAdapter merge operation error

    Hello,
    I run into a problem when trying the DBAdapter merge operation. I believe the merge operation first executes a query operation based on the primary keys, if not found, then will execute an insert operation, my problem is when I pass in the input as " " for one primary key, seems the merge operation internally transform it to "" then do the query, so there is no record found, then it will do the insert with the right primary key " ", which results in the violation of the unique constraint (suppose I inserted a record with primary key " " before).
    Does anyone have any suggestion for this?
    Thanks.
    Leo

    I'm using database triggers as well, if your acquanted with pl/sql that would be the 1st choice, especially because you can generate the needed triggers for all your audit columns.
    On the other hand you can define annotations in JPA, EJB3.0 now to populate your audit-columns automatically, maybe this can be done as well in the toplink mapping files?
    It should be possible, but I don't now until which level annotations are supported in toplink used by the dbAdapters.
    Kind regads,
    Nathalie

  • Using the match/merge operator

    Hi guys,
    I have created a simple table with 4 columns:
    EMPLOYEES
    - employee_id
    - emp_firstname
    - emp_lastname
    - emp_telephone
    I have placed 5 entries in the table:
    11, jane, doe, 80980980
    12, william, gates,6876876868
    13, john, anderson, 545646546
    14, michelle, millo, 340580334
    15, john, anderson, 545646546
    Row 13 and 15 are duplicates, except for the employee_id. I'm trying to use the match-merge operator to check for matches on emp_firstname, emp_lastname and emp_telephone. I would like to merge the rows matching on firstname, lastname and telephone number, and would like to keep the lowest employee_id as PK.
    I have tried to use the match-merge operator with the following settings;
    Input connections:
    - employee_id
    - emp_firstname
    - emp_lastname
    - emp_telephone
    Merge output
    - employee_id
    - emp_firstname
    - emp_lastname
    - emp_telephone
    Xref output
    none
    Match bins:
    - emp_firstname
    - emp_lastname
    - emp_telephone
    Match rules:
    MA_0, all_match
    Merge rules:
    emp_firstname: all match
    emp_lastname: all match
    emp_telephone: all match
    When I debug the match merge operator I get " 4 in, 4 out", but I expected to have "5 in, 4 out". Am I using this match/merge operator the right way?
    thx for you help!
    michiel
    null

    Hi Robert,
    I tried on 3 database installations (all 10.2). there is no parameter DB_BLOCK_BUFFERS set. And i do not assume that there is a reasn for increasing the db_cache_size - means: why i did not get any error for that presumed case?
    btw: can you explain why i should increase db_cache_size?
    thanks,
    Andreas

  • Pl/sql procedure for match-merge operator

    I have used the match-merge operator in OWB. I want to implement the same match-merge operation using a pl/sql procedure. Please help.

    Yes sure. Lets say, we have a table tab1, which has the following structure and data:
    First_name Last_name Address City
    JACK ANDREWS XYZ NY
    ANDREWS JACK NY
    Now, i want to write a procedure which matches and merges the above two records, into a single record.The matching is done with the help of the first_name and last_name columns.

  • Multiple record upsert - Merge operation problem using DB Adapter

    Hi,
    I am trying to insert/update multiple records using Invoke activity of BPEL and DB Adapter Merge operation.
    I am facing 0036 - Missing expression error. When i try with single record, the operation is working fine.
    Tried setting DB Adapter log level to 32 Finest. Could not find much info in the logs.
    SOA Version - 11.1.1.7

    Hi,
    I believe NVARCHAR is an unsupported type...
    The following document lists the supported data types for SQL Server stored procedures and functions... NVARCHAR is not in the list... :-(
    http://docs.oracle.com/cd/E23943_01/integration.1111/e10231/adptr_db.htm#CHDEBEEE
    Hope this helps...
    Cheers,
    Vlad

  • How do I make Merge operation into the target table case insensitive?

    Hi All,
    We have a target table that has a varchar 2 column called nat_key and a map that copies over data from a source table into the target table.
    Based on wheteher the values in the nat_key column matches between the source and the target, an update or an insert has to be done into the target table.
    Let us say target table T has the following row
    nat_key
    EQUIPMENT
    Now, my source table has the same in a different case
    nat_key
    equipment
    I want these rows to be merged .
    In the OWB map, I have given the property of nat_key column in the target table as 'Match while updating' = 'Yes'. Is there a built in feature in OWB, using which I can make this match as case insensitive?
    Basically, I want to make OWB generate my mapping code as
    if UPPER(target. nat_key)=upper(source.nat_key) then update...else insert.
    Note: There is a workaround with 'Alter Session set nls_sort=binary_ci and nls_comp=linguistic', but this involves calling a pre-mapping operator to set these session parameters.
    Could anyone tell me if there is a simpler way?

    Hi,
    use an expression operator to get nat_key in upper case. Then use this value for the MERGE. Then nat_key will only be stored in upper case in your target table.
    If you have historic data in the target table you have to update nat_key to upper case. This has to be done only once and is not necessary if you start with an empty target table.
    Regards,
    Carsten.

  • Purchasing concerns while merging operating units

    Hi all,
    Can any body please guide regarding the concerned entities of Purchasing while merging two operating units?
    Regards,
    Abdul Rehman.

    Hi Abdul,
    While merging 2 OU, the following purchasing entities you should review as per opinion.
    (1) Items of old OU should be created/assigened to merged OU, if it is not exists in merged OU.
    (2) Similary , Suppliers of old OU should be created to merged OU, if it is not exists in merged OU.
    (3) You should go for the redesign Posiition hierarchy and PO approval limit groups.
    (4) New Payment terms should be require to create, if it is new for merged OU.
    (5) Creation of new buyers are required.
    HTH
    Sanjay

  • Identifying old internal record id after merge operation

    Hi,
    Since a merge record operation creates a new record, with a new internal record id, is there a way to find the the old record id's that were merged into the new record?  It would be ideal for us to have a method through the Java API's.
    This is also particularly necessary for us to track change tracking through every merge.  Is there a way to track change tracking for a record through all merges?
    Thanks in advance.

    Hi,
    MDM provides Change Tracking functionality where you can track the changes like Record Addition, Modification and deletion. In case of Record Merging, it first delete the individual records to be merged and creats a new merged record. Hence you will find three entries in the Change Tracking if 2 records are involved in Merging process (depending on number of fields on which Change Tracking has been enabled).
    You can view the Changes at database level by Quering the A2i_CM_History table.
    Change Tracking in MDM
    You can also make the Change Tracking UI available in the Web tab of MDM Data Manager
    http://help.sap.com/saphelp_mdm550/helpdata/en/45/c87d0243e56f75e10000000a1553f6/frameset.htm
    Configuring a Change Tracker
    Regards,
    Jitesh Talreja

  • Merge Operating Units

    Hi
    Does anybody know how to Merge two operating units in EBS R12 ?
    Thanks in Advance
    Karbi

    I believe this is possible - it is not a trivial exercise. You will need to engage a consulting organization (Oracle or third-party, which has done these kinds of merges before) to do this.
    HTH
    Srini

  • Merge operation in Lightroom cc turn off the active filter

    Merge to HDR / Panorama turn off the active filter in LR

    Yes, this is to prevent confusion when the merge result falls outside of the active filter and is thus hidden from the user.  Sometimes it will, sometimes it won't - so we chose consistency of behavior.
    You should be able to prevent this by clicking the padlock icon in the upper right of the grid view and filter area. This will lock the filter.

  • Merging multiple rows in to a single row (when rows meet merging criteria)

    Hi 
    I have a scenario to merge multiple rows in to a single rows when the data in those rows fall in merge criteria .Below is how my data is 
    Now the merging logic for the above rows is , we need to combine multiple rows in to a single row when the data in those rows permits us to do in that way. Simply saying , its like sandwich where we combine multiple things to a single piece.The output for
    the above rows should be
    Here  we combined Row 1 ,2, 3 in to a single row as the data in those rows permits to merge in to single row. But the row 4 cannot be combined to any of those rows because the data in those rows doesn't permits us do a merge ( As the value of the column
    JobSource for the row 4 is different from the other rows ) .
    My original data has 56 columns , but for readability i kept only 9 columns. 
    can you please throw some idea on how to achieve this scenario. I know we need to use CTE for achieving this, but i am not able succeed in doing an iteration on multiple rows.
    Appreciate your response .

    Thanks for your reply .
    Rule for merging is simple . First of all there is no unique row identifier for each row , the fact table is not having an identity column in the database . I called row 1 , row 2  etc in my post above only to make better explanation of my scenario.
    The rule for merge is below. 
    1) we can combine only when the data in a column for one row is null & the data in same column for the other row is not null . It should also satisfy the condition where the data in other columns should conflict each other.
    2) Data for all columns for the merging rows should not be conflicting (i.e. we should not merge the rows when the data in a column is not equal to the same column in the other row
    ,considering not null value)
    Steps in merging the above source data :
    1) Consider the case of row 1 and row 2 in the source, we can combine these rows as the data is satisfying the rule 1 for columns (Jobsource,Flight, Package,Update,Iscancelled
    ,Result, Severity) and columns (JobID and RuleName ) fall under rule 2.  we merge these two rows in to a single row and keep in that in the table.
    2) Then the resulting row is again merged with the second row which is present above by applying the rule 1 and rule 2 . Below would be output of merge operation.
    Now there would be only two rows in the output . But these rows cannot be merged as the data doesn't satisfy the merge rules 2 . As Jobsource for the row 1 in the above output is "PresubmissionSource" which is not equal
    to "PostSubmission" jobSource which is in row 2. So these two rows are left unmerged .So the above two rows would be the output of merge operation on my source data.
    This process has to be repeated for all the rows in the table. As of now my table as 92 Million rows with 56 columns which need to be considered for merging rows. I replicated my scenario in 9 columns and 4 rows to understand better.

Maybe you are looking for

  • Persistent and transient objects

    New operator creates persistent objects in the case of fields of a class. Local variables are put on the RAM stack. Does that mean, that, in the case of local variables, new operator creates objects in RAM, or I have to use makeTransientByteArray? Ed

  • [ANDROID] Authenticate user with Google Account?

    Hello I'm currently developing in Flash Builder 4.5 (Flex Mobile Project) and I'm about to launch a closed beta, and I'd like to do that by authenticating the testers with their Google Account that they use on their Android phones. So now I wonder if

  • Writing an onClipEvent as a function

    Hi all, I'm currently using this to scale different symbols in various parts of my movie: onClipEvent(enterFrame) { speed = .3; this._xscale += speed; this._yscale += speed; As I'm attaching that directly to the movie clip instances it's obviously no

  • Exception in CRM system after creating post goods issue in ECC

    Hi Folks, We are facing an issue in CRM system. I will tell the scenario in details so that it would be helpful to understand, We are creating sales order in CRM system and it got replicated to ECC correctly. We have maintained action definition to t

  • ASCII and Unicode problem...

    Would you happen to know if InDesign CS3 still recognizes ASCII characters in an Applescript? I did some tweaking of a search & replace script (formerly used in Quark 6.5), to apply in InDesign, but it doesn't seem to work. I read online that when Le