IBM webMethods Hybrid Integration

IBM webMethods Hybrid Integration

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
Expand all | Collapse all

problem update replace attribute

  • 1.  problem update replace attribute

    Posted Sat March 17, 2007 01:53 AM

    Hi,
    I want to replace an attribute element and I don’t know how to do it. With normal elements it works but with attributes I don’t know what more to test.
    This is my query to see it more clearly.

    It works in this case:

    update let $a:= input()/DVD/Media/DMS1:ClipFramework[last()]
    do (
    replace $a/extension_rp210Elements:IsOptional/text() with “false”
    )

    With attributes not works:

    update let $a:= input()/DVD/Media/DMS1:ClipFramework[last()]
    do (
    replace $a/@rp210Elements:InstanceUID/text() with “21.80.00.00.00.00.00.00.00.00.00.00.00.00.00.00”
    )

    Maybe with attributes(@) it is necessary any special command.
    If someone could help me I will be very grateful.
    Thanks a lot,
    Diego


    #API-Management
    #webMethods
    #Tamino


  • 2.  RE: problem update replace attribute

    Posted Sat March 17, 2007 07:35 AM

    See if this syntax will work for you:

    update let $a:= input()/DVD/Media/DMS1:ClipFramework[last()] 
    do ( 
    replace $a/@rp210Elements:InstanceUID with attribute rp210Elements:InstanceUID {"21.80.00.00.00.00.00.00.00.00.00.00.00.00.00.00" }
    ) 

    #API-Management
    #Tamino
    #webMethods


  • 3.  RE: problem update replace attribute

    Posted Sat March 17, 2007 10:27 AM

    Thanks a lot, it works perfectly.
    Regards,
    Diego


    #Tamino
    #API-Management
    #webMethods