Updating XQuery with WLST

Hi,
I'm new to Weblogic. Need a little help with this.
I have two separate applications : 1 which does the dynamic invocation callout (application A) and the other serving as the xquery repository (application B).Application A does a dynamic transformation using a uri pointing to a xq file on application B, Application A seems to cache the xq file. If I update the xq file on application B, the only way Application A will pick up the changes is to redeploy application A (i.e. crudely flush it's cache). Is there any way I can update the XQuery file using WLST?
Thanx

As I am not able to use IF-ELSE in Oracle for select statementsHow about a CASE statement?
If each query is always meant to return a single aggregated column (and of course only one row), then you can use this :
SELECT CASE WHEN param_1 IN ('VAL1', 'VAL2')
             THEN (
               SELECT ...
               FROM emptable, XMLTable( ... )
            WHEN param_1 IN ('VAL3', 'VAL4')
             THEN (
               SELECT ...
               FROM addresstable, XMLTable( ... )
        END AS Orders
FROM dual;If you prefer the UNION approach, then :
Here, if the Param.1 is "NAME" then the outcomes as <Rowset></Rowset> + Output of other query (which only thing I want)That's because of the XMLAgg aggregate function.
An aggregate function without GROUP BY always returns one row, even though there's no row in the original result set.
SQL> SELECT XMLElement("Rowset", XMLAgg(rw.column_value))
  2  FROM emptable ul
  3     , XMLTable('/Rowsets/Rowset/Row' passing ul.text) as rw
  4  WHERE 1 = 0
  5  ;
XMLELEMENT("ROWSET",XMLAGG(RW.
<Rowset></Rowset>
You can group by an empty list of column to force the required behaviour :
SQL> SELECT XMLElement("Rowset", XMLAgg(rw.column_value))
  2  FROM emptable ul
  3     , XMLTable('/Rowsets/Rowset/Row' passing ul.text) as rw
  4  WHERE 1 = 0
  5  GROUP BY ()
  6  ;
XMLELEMENT("ROWSET",XMLAGG(RW.
You should also use UNION ALL instead of UNION so that Oracle doesn't bother performing any unneeded sort operation.
What is the purpose of RTRIM in your examples? I don't see any reason to call it over an XMLType instance, furthermore it performs an implicit datatype conversion to VARCHAR2 which can potentially cause errors.
If you need to serialize the resulting XMLType column then use the appropriate methods getStringVal(), getClobVal() or XMLSerialize function (11g).
Edited by: odie_63 on 7 nov. 2012 23:24

Similar Messages

  • Update deployment plan definition with WLST

    Hello,
    I would like to write a script in order to get the existing deployemnt plan of my deployed application (Deployement plan is yet modified, I don't want to use loadApplication). Then I would to update my deployement plan (update/add work manager constraints).
    I can't find any WLST api to do that. The Weblogic console doesn't record the actions when I do it through the console.
    I would like top the the same as this link http://download.oracle.com/docs/cd/E15051_01/wls/docs103/config_scripting/updateplan.html
    But with a deploymenPlan got from the server and not from the filesystem
    The only way I see is to use a Java parser un Jython to update the existing deployemnt plan and then, redeploy the application but This solution is very heavy in term of developpment. It should be more efficient when a built in parser
    Could you please help me giving me some information about how to update deployement plans of a yet deployed application with WLST ?
    Thank you !
    C.

    Thank you for answering.
    In fact, I have found the solution for my use case according to the previous html link
    The WLST plan seems to be accessible only by file system.
    If your application is yet deployed with a deployment plan and you want to update this plan, you have to login on the admin server via WLST,get the application absolute path and the plan absoluth path :
    cd ("AppDeployments/" + INTERNAL_APP_NAME)
    appPath  = cmo.getAbsoluteSourcePath()
    planPath = cmo.getAbsolutePlanPath()and then, load the existing plan :
    plan = loadApplication(appPath, planPath)after that, you can use the api described at the following link http://download.oracle.com/docs/cd/E15051_01/wls/docs103/config_scripting/updateplan.html to update the plan.
    Then, you have to redeploy the application :
    redeploy(APP_NAME)Thank you for helping !
    C.

  • Issue in Invoking an Updatable View with Instead of Trigger

    Hi,
    I am trying to insert a record using Updatable View with Instead of Trigger. When i try to save the data, i get the below error:
    java.sql.SQLException: ORA-01403: no data found
    ORA-06512: at line 1
    at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:457)
    at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:405)
    at oracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:889)
    at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:476)
    at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:204)
    at oracle.jdbc.driver.T4C8Oall.doOALL(T4C8Oall.java:540)
    at oracle.jdbc.driver.T4CCallableStatement.doOall8(T4CCallableStatement.java:213)
    at oracle.jdbc.driver.T4CCallableStatement.executeForRows(T4CCallableStatement.java:1075)
    at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1466)
    at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:3752)
    at oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedStatement.java:3887)
    at oracle.jdbc.driver.OracleCallableStatement.executeUpdate(OracleCallableStatement.java:9323)
    at oracle.jdbc.driver.OraclePreparedStatementWrapper.executeUpdate(OraclePreparedStatementWrapper.java:1508)
    at weblogic.jdbc.wrapper.PreparedStatement.executeUpdate(PreparedStatement.java:172)
    at oracle.jbo.server.OracleSQLBuilderImpl.doEntityDML(OracleSQLBuilderImpl.java:432)
    at oracle.jbo.server.EntityImpl.doDMLWithLOBs(EntityImpl.java:8566)
    Can someone help me resolve this issue?
    Also it would be great if you can share Sample codes for Invoking an updatable view with instead of trigger on Save/commit.
    Regards,
    Jeevan

    As a trigger is executed in the db and not in your app it's really hard to help as you did not give any useful information.
    Have you read this blog http://stegemanoracle.blogspot.com/2006/03/using-updatable-views-with-adf.html ?
    Timo
    Edited by: Timo Hahn on 22.09.2011 09:15
    And my friend google also found http://technology.amis.nl/blog/1447/adf-business-components-resfresh-after-insertupdate-and-instead-of-triggers

  • I updated my computer to the new software and now the iPhoto has a circle with a line through it.  When I try to update, it pops up to say "These apps cannot be accepted by your apple id". Then will say "update unavailable with this apple id" how do i fix

    I updated my computer to the new software and now the iPhoto has a circle with a line through it.  When I first try to open it the pop us says: "You can't use this version of the application "iPhoto" with this version of OS X. Version: 9.2.1"  When I try to update, it pops up to say "These apps cannot be accepted by your apple id - These apps were already assigned to another Apple ID and they will be available in that Apple ID's purchases list.  If you don't have access to that Apple ID and want to receive future updates, you will need to purchase the application".  I checked and there is nothing under the "purchases" in my App store.  Then will say "update unavailable with this apple id - This update is not available for this Apple ID either because it was bought by a different user or the item was refunded or canceled." Then the third pop up says "We could not complete your request. There was an error in the App Store.  Please try again".  Just want to know how do to fix.

    After I upgraded to Mavericks I was also having this message when I tried to update. There was a previous post about this problem which offered this simple solution which worked for me:
    b0n0b0
    Re: Recently upgraded to Maverick from SnowLeopard. Unable to get updates from App store.
    Mar 15, 2014 9:05 AM (in response to Terence Devlin)
    Got it! Thanx.  What I did was go to my account, check that they had my new ID and Password which they did, then hit reset button. All fixed.

  • After the most recent FF update, FF 3.6.6 will not load, citing the error message: "XULRunner / Error: Platform version '1.9.2.3' is not compatible with minVersion =1.9.2.6 / maxVersion". Tried updating XULRunner with no luck. Downloaded fresh copy and

    After the most recent FF update, FF 3.6.6 will not load, citing the error message: "XULRunner / Error: Platform version '1.9.2.3' is not compatible with minVersion>=1.9.2.6 / maxVersion". Tried updating XULRunner with no luck. Downloaded fresh copy and installed. Still no luck.
    == This happened ==
    Every time Firefox opened
    == FF updated to 3.6.6 ==
    == User Agent ==
    Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; GTB6.4; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729)

    Do a clean reinstall and download a fresh Firefox copy from http://www.mozilla.com/firefox/all.html and save the file to the desktop.
    Uninstall your current Firefox version and remove the Firefox program folder before installing that copy of the Firefox installer.
    It is important to delete the Firefox program folder to remove all the files and make sure that there are no problems with files that were leftover after uninstalling.
    You can skip the step to create a new profile, that is not necessary for this issue.
    See http://kb.mozillazine.org/Standard_diagnostic_-_Firefox#Clean_reinstall

  • "Update unavailable with this Apple ID" when trying to update or re-download FREE apps purchased with this same ID

    This morning I tried to update my apps through the app store. Many of them updated, but some (Soundcloud, Evernote, Viber, and IMDB) gave me the error message "Update unavailable with this Apple ID"
    I removed those apps and tried to re-install them, only to receive the same message. I then logged out of the App Store and logged back in but this did not make a difference.
    These apps are not showing up on my "purchased" list.
    I have only ever had one Apple ID, and have been using and updating these free apps for some time now.
    Any idea how I can resolve this? Searching the forums has not helped at all.

    Same problem here. IMDB, TWC (weather app) Goodreader… Started this morning, out of the blue.
    After deleting IMDB (hoping to reinstall), that app cannot be installed again! Trying to, gets you the same “Update unavailable” error.
    Also, the problematic apps are not listed in my “Purchased” list (which is the real problem I think).
    I also tried through iTunes. Same problem.
    Can someone confirm that the problem apps are not showing in your purchased list?
    I don’t know if it’s on Apple’s side (in which case it will get fixed) or on my side (meaning I will have to do something).
    (I contacted Apple, waiting for reply.)

  • Hey, ive recentley got a new phone and im trying to download apps but it wont let me. And when i click download this is what comes up, "Update unavailable with this apple ID.

    Hi, ive recentley got a new iphone 5C. I am trying to download apps on the appstore but it wont let me. It says this: Update Unavailable with this Apple ID.
    This update is not available for this apple ID because it was bought by a different user or the item was refunded or cancelled.
    How do u fix this??

    Apps are forever tied to the AppleID used to download them.
    Either use the original AppleID or delete the app and then download again
    using your current AppleID. You cannot transfer an app from one AppleID to
    another, nor can you merge AppleIDs.

  • MacBook Pro battery had accumulated more than a 1000 charges, and stopped functioning unexpectedly. Went and got the battery replaced. Just saw that SMC Firmware 1.6 update deals with this. Possible to get my money back?

    MacBook Pro battery had accumulated more than a 1000 charges, and stopped functioning unexpectedly. Went and got the battery replaced. Just saw that SMC Firmware 1.6 update deals with this. Possible to get my money back?

    The firmware update corrects an error that may occur, however the techs would have checked the condition of the battery prior to installing a new one.  If the battery was questionable, the firmware update was really not too important.
    You can check the battery condition by going to the apple, left side of the menu bar, About This Mac, More Info, System Report, Hardware, Power and see what it says about Cycle Count, Condition, Capacity: Condition anything but Normal needs to be checked and may need to be replaced.
    The cycle count of 1,000 charge cycles is the typical life of a Lithium-Ion battery, the point at which the capacity drops to 80% of the as built capacity.

  • Unable to update iPhoto and iMovie. "Update Unavailable with This Apple ID"

    I updated to Yosemite and all went well but for the message "Update Unavailable with This Apple ID" for the two apps iPhoto and iMovie. I have tried using the terminal window and used code that others have suggested and obtained a SmartSearch. I deleted everything in that folder and I still can't update these two apps. The other apps updated without problems. Thanks for any help.

    For a couple of years now, the verson of the iLife apps that come preinstalled on new Macs are the Mac App Store (MAS) versions. MAS apps have the Apple ID that bought them encoded in the app as an anti-piracy scheme. Since these apps are preinstalled, before using any of the three apps, the new Mac owner must open the MAS, go to the Purchases pane and accept these apps into their MAS account. This allows the MAS to encode the owners Apple ID into the apps.
    Failure to accept these apps into your account and have them encoded with your Apple ID before using one of them renders the apps "as is" and they cannot be updated or downloaded to another Mac. The only way that I know of to rectify the problem is to use OS X Recovery to erase the Mac and reinstall OS X and the iLife apps, so that the initial setup can be attempted again and the apps be accepted into the MAS account and encoded with the Apple ID.

  • Hello there - how can I share my iTunes library between two users on the same computer? I put the library in a shared folder between both and have selected this library on both as well, but when I update iTunes with music etc it only appears on one?

    Hello there - how can I share my iTunes library between two users on the same computer? I put the library in a shared folder between both and have selected this library on both as well, but when I update iTunes with music etc it only appears on one?

    Thank you Joe - I tried this but it's only showing a teensy amount of music - the stuff on the second users account as opposed to the giagntic library on the 'main' account. I actually went to a Genius Bar and they said that apple doesn't really want you to share music between accounts - parents don't want to hear their kids music etc. Which seemed strange, but it might be the case sadly   Thanks anyway!

  • Update Unavailable with This Apple ID

    For years, my wife and I have shared the same Apple ID, so that we could share music and apps without having to pay for them twice.
    With the introduction of Family Sharing, I thought we could bypass that.
    I had my wife create her own Apple ID. I enabled Family Sharing, sent her an invite, which she accepted, and she now appears as an "Adult" under Family Sharing iCloud settings.
    I signed out of her iPhone and iPad with my Apple ID, and signed back in using her Apple ID. Everything appeared to work fine, all apps still launch, she's able to download new apps herself, etc. However, once a few apps tried updating, she received the message...
    Update Unavailable with This Apple ID.
    This update is not available for this Apple ID either because it was bought by a different user or the item was refunded or canceled.
    I get what's happening. The apps on her devices are tied to my account, and she's now trying to update those apps using her account. But as a member of Family Sharing, this should work. I'm thinking this is an oversight of Apple's in how the system works. Otherwise, the only way around this is to remove every app from her device and re-download them using hers. That's 100+ apps between her iPhone and iPad.
    Any workaround to this? I've rebooted. Signed out of and back into iTunes. Not sure what else to try other than to just start uninstalling and reinstalling apps...

    Yep you're not alone, I've got exactly the same issue.
    Hoped 8.0.2 would resolve it but no.
    Some apps are 'family' aware and update ok, others not. Can't delete and re download as iTunes still sees them in the family share.
    Had to sign out of iTunes and sign into our old shared iTunes account to get the app updates to work. What a PITA.
    Tried many things before, sign out/in of both iPhones, switch off/on of app sharing, remove and resign up for family share, but no joy.
    Switch iTunes id, update, switch back, was the only fix I could find.

  • Why i'm unable to update App with different Apple ID? (it gives me an error: Impossible to connect to iTunes Store)

    Hello,
    i installed a lot of Apps on my iPad (both free and purchased), then a sad day  i had to change my apple ID (due to some mistakes in configuring the ipad for my wife with a different apple ID and for icloud...).
    Now i have apps with my last apple ID account and apps with my previous one.
    When i have to update Apps with my last apple ID, there's no problem, but when i try to update Apps installed with the OLD one a problem occurs and even if i type the right password for it i get always the same message: Impossible to connect to iTunes Store!
    Password for old apple ID is correct because i can log on line at account page on https://appleid.apple.com/it/
    I read everywhere that having Apps with different account on the same Ipad is allowed, so....What's the Problem?? 
    thank you in advance.
    Bye

    Content and Apple IDs -
    Content is forever tied to the Apple ID that bought it. Apple does not transfer content from one Apple ID to another. Apple does not merge Apple IDs. You will never be able to access your content bought with another Apple ID with a new Apple ID.

  • I have one iPhone 4s, one iPad 2 and wife's iPhone 4s. yesterday I have updated all with ISO 8 under one apple id, now my problem is that in same WiFi when Any of phone receive phone all the three gazettes ring simultaneously . how to resolve this.

    I have one iPhone 4s, one iPad 2 and wife's iPhone 4s. yesterday I have updated all with ISO 8 under one apple id, now my problem is that in same WiFi when Any of phone receive phone all the three gazettes ring simultaneously . how to resolve this.
    regards
    rbv

    Tell your wife to get her own Apple ID. If you do not want continuity/handoff to work with calls, on both devicesgo to Settings==>>FaceTime==>> Turn OFF iPhone cellular calls.

  • ı have bought second hand ipad. 17 apps which were downloaded by previous user with his or her apple id. I need to update them but when I try, ı can't update them with my own apple id. Device ask me to update with the id and password of previous user.

    ı have bought second hand ipad. 17 apps which were downloaded by previous user with his or her apple id are waiting to be updated. I need to update them but when I try, ı can't update them with my own apple id. Device ask me to update with the id and password of previous user. I tried I forgot but this didn't work.  So how can ı have my device forget the previous ID and use my own to update exsisting apps.
    <Email Edited by Host>

    Restore the device to factory settings with iTunes. 
    Then launch the App Store app on the iPad and sign in with your Apple iD and password:
    OT

  • I'm using Iphone 5 .After updating it with the latest software i.e iOS 7.0.6 I'm not able to see the wats app and imsg on my notification until and unless i activate the "Show on Lock Screen" which was not same as in the earlier software version.Help plz

    I'm using Iphone 5 .After updating it with the latest software i.e iOS 7.0.6 I'm not able to see the wats app and imsg on my notification center when my phone is locked until and unless i activate the "Show on Lock Screen" under each application. which was not same as in the earlier software version.I dnt want my messages or watsapp msges to be displayed on home screen when locked but should be displayed on the notification center on lock condition.
    Please suggest a solution or @Apple please get a software release which can remove this bug .

    We aren't Apple, just users like you. Have you tried a reset? Hold down the home button along with the sleep/wake button until the screen goes black and you see the Apple, then let go. (No data loss)

Maybe you are looking for