XSD with xs:any and then querying in the xs:any part

Hi,
I'm having troubles querying for elements in an xs:any part of a schema. Trouble as in: can't get to the data anymore using simple xquery/xpath expressions.
I have a XSD with an xs:any element:
(the actual XSD is bigger, this is a smaller, test version)
<?xml version="1.0" encoding="windows-1252"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
           targetNamespace="http://localhost/anydata.xsd"
           xmlns:xdb="http://xmlns.oracle.com/xdb"
           xmlns="http://localhost/anydata.xsd"
           elementFormDefault="qualified"
           attributeFormDefault="unqualified"
           version="1.0">
    <xs:element name="anydata" type="anydataType" xdb:defaultTable="ANYDATA"/>
    <xs:complexType name="anydataType">
        <xs:sequence>
            <xs:any namespace="##any" minOccurs="0" maxOccurs="unbounded" processContents="lax" />
        </xs:sequence>
        <xs:attribute name="refId" type="xs:string" use="required" />
    </xs:complexType>
</xs:schema>I register the xsd and create the default table (following binary xml) with the following code (after uploading the anydata.XSD using ftp to /public/tmp):
set serveroutput on
VAR schemaURL VARCHAR2(256)
VAR schemaPath VARCHAR2(256)
BEGIN
   :schemaURL := 'http://localhost/anydata.xsd';
   :schemaPath := '/public/tmp/anydata.xsd';
END;
-- Delete schema if already there, delete with cascade
BEGIN
  DBMS_XMLSchema.deleteSchema(
    schemaurl=>:schemaURL,
    delete_option=>DBMS_XMLSchema.Delete_Cascade_Force);
END;
BEGIN 
    dbms_xmlschema.registerSchema(
    SCHEMAURL  => 'http://localhost/anydata.xsd',
    SCHEMADOC  => xdbURIType('/public/tmp/anydata.xsd').getClob(),
    LOCAL      => TRUE,
    GENTYPES   => FALSE,
    GENBEAN    => FALSE,
    GENTABLES  => TRUE,
    FORCE      => FALSE,
    OPTIONS    => DBMS_XMLSCHEMA.REGISTER_BINARYXML,
    OWNER      => USER);
END;
/Inserting some data with an <a>a</a> element:
INSERT INTO anydata VALUES (XMLType('<?xml version="1.0" encoding="ISO-8859-1"?><anydata xmlns="http://localhost/anydata.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://localhost/anydata.xsd http://localhost/anydata.xsd" refId="a12ab"><a>a</a></anydata>'));No problems here:
SQL> select * from anydata;
SYS_NC_ROWINFO$
<?xml version="1.0" encoding="ISO-8859-1"?>
<anydata xmlns="http://localhost/anydata.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://local
host/anydata.xsd http://localhost/anydata.xsd" refId="a12ab">
  <a>a</a>
</anydata>Select the refId is no problem:
SQL> SELECT * FROM XMLTable('
  2  declare default element namespace "http://localhost/anydata.xsd"; (: :)
  3  for $f in ora:view("anydata")
  4      return $f/anydata/@refId'
  5  ) xtab;
COLUMN_VALUE
a12abBut getting the <a> value... seems to be impossible, whatever I try:
SQL> SELECT * FROM XMLTable('
  2  declare default element namespace "http://localhost/anydata.xsd"; (: :)
  3  for $f in ora:view("anydata")
  4      return $f/anydata/a'
  5  ) xtab;
SELECT * FROM XMLTable('
ERROR at line 1:
ORA-19276: XPST0005 - XPath step specifies an invalid element/attribute name: (a ='http://localhost/anydata.xsd')So probably something to do with <a> not being part of the schema. I've also tried the following, to see if I can only apply the namespace to the appropriate elements:
SQL> SELECT * FROM XMLTable('
  2  declare namespace ad="http://localhost/anydata.xsd"; (: :)
  3  for $f in ora:view("anydata")
  4      return $f/ad:anydata/a'
  5  ) xtab;
SELECT * FROM XMLTable('
ERROR at line 1:
ORA-19276: XPST0005 - XPath step specifies an invalid element/attribute name: (a)Doesn't help either.
Anyone ever seen this and solved it?
Message was edited by:
Tijink

Hi,
I've patch my system with the following patch (id 7009297):
ORACLE 11G 11.1.0.6 PATCH 3 BUG FOR WINDOWS X-64 BIT AMD
And the result
SQL> SELECT * FROM XMLTable('
  2    declare namespace ad="http://localhost/anydata.xsd"; (: :)
  3    for $f in ora:view("anydata")
  4        return $f/ad:anydata/ad:a'
  5  ) xtab;
<a xmlns="http://localhost/anydata.xsd">a</a>So, it works. Thanks for the help!
null

Similar Messages

  • Zoom and pan with Ken Burns and then stop and hold the image

    Hi all,
    I'd like to zoom and pan on a photo with Ken Burns and then stop at the "end" -cropping and hold the image there on my project for a few seconds. Is this possible?

    I found a new solution.
    I select the ready "Ken Burnsed" photoclip and ctrl-click and choose copy, and then paste the exactly same kind of clip right behind the original. Then i go to the 'cropping, ken burns and rotation'- window, make shure that the start box is on the same crop as the ending of the original clip ( you can switch between start and end crops from the arrow thingy in the corner of the box) , and click crop. There I have the righty cropped stillframe right behind of the original.
    I don't know if this is the right method, but it works thanks for everyone for helping, and if you find a better way, please post. I have this thread subscribed.
    Message was edited by: AnttiS

  • Airport Express will not stop flashing amber light; Reset multiple times; Works for a second with green light and then resumes flashing amber

    I bought an Airport Express to extend my Airport Extreme about a month ago. It worked great until 2 weeks ago it started flashing amber. I reset it and set it up via airport utility and it would work for a little while, with great connection, and then it resumes the flashing amber light. Here is the error message:
    "This AirPort base station was unable to extend the wireless network. Make sure the wireless network you're trying to extend was set up and is working correctly, that you entered a matching wireless network password into this device, and that this device is in range of the wireless network."
    The Airport Extreme is in working condition, in range, and entered in correctly. I do not understand how it can work great for a second and then stop.
    Thanks!

    Power off both the AirPort Extreme and AirPort Express
    Wait a few minutes
    Power up the AirPort Extreme, and let it run a few minutes
    Then, power up the AirPort Express
    If you continue to have difficulty, ask Apple to replace the AirPort Express.

  • When i take a picture with my iphone and then forward the picture in an email (regardless of picture size) it will not send - any thoughts????? Thanks.

    When I take a picture with my iPhone and then forward the picture to an emaila ddress (regardless of picture size) it will not send the email with the pciture enclosed - any thoughts on how to fix ?????
    Thanks -

    The collum to the right listed similar problems.  The solution appears to be that under smtp outgoing settings the user name and password are listed as optional.  I have not plugged in the information and it seems to be working.  However from my office it always allowed the relaying.  The true test will be when I try to respond later from the road.
    Thank you for your help.

  • TS1717 Trying to download iTunes onto PC installed with windows vista. Download keeps getting to 99% with 1 second remaining and then freezes / does nothing? Any help appreciated.

    Trying to download itunes onto PC installed with windows vista. Download keeps getting to 99% with 1 second remaining and then freezes / does nothing? Any help appreciated.

    I solved the problem! The updates orignally were downloaded to the C: drive of the server. I've since moved them to the E: drive and for some reason the Content folder in IIS didn't change the file path to the new WSUScontent folder.
    The root cause for this was failing to use the UTILITY designed for this very purpose.
    I edited the virtual directory settings in IIS and was able to put the correct path in.
    You still need to use the UTILITY.. to fix all the other stuff you're still missing.
    In the %ProgramFiles%\Update Services\Tools folder...
    WSUSUTIL MOVECONTENT E:\WSUS E:\WSUS\MoveContent.LOG -SKIPCOPY
    This problem was caused by moving the WSUS updates to a different local drive.
    No. This problem was caused by IMPROPERLY moving the WSUS updates to a different local drive.
    Lawrence Garvin, M.S., MCSA, MCITP:EA, MCDBA
    SolarWinds Head Geek
    Microsoft MVP - Software Packaging, Deployment & Servicing (2005-2014)
    My MVP Profile: http://mvp.microsoft.com/en-us/mvp/Lawrence%20R%20Garvin-32101
    http://www.solarwinds.com/gotmicrosoft
    The views expressed on this post are mine and do not necessarily reflect the views of SolarWinds.

  • Hi! I've been using Goldmine contact management software for many years and syncing with Companion Link successfully, then ITunes to the IPhone. Suddenly, my IPhone is not recognized and won't sync. I see a message telling me to dock the phone? Any ideas?

    Hi! I've been using Goldmine contact management software for many years and syncing with Companion Link successfully, then ITunes to the IPhone. Suddenly, my IPhone is not recognized and won't sync. I see a message telling me to dock the phone? Any ideas? Thanks for any assist!

    Hi Ken,
    Dennis here from westport. I too am a goldmine user for many years and would love to know how you sync.
    I am looking at a product called wmobile, but may be problematic on my current system.
    thanks for any help...

  • When i open my emails with outlook first and then with my ipad 4, the ipad does not show me that i have new mail despite that it actually downloads them. iphone 3g and 4s used to do that. any suggestions please?

    when i open my emails with outlook first and then with my ipad 4, the ipad does not show me that i have new mail despite that it actually downloads them. iphone 3g and 4s used to show them as new emails. any suggestions?

    1. Open iTunes.
    2. Click the View option in the iTunes menu.
    3. Select the Show Sidebar option.
    Connect your phone, select it in the Sidebar...the various tabs will now show as before.

  • I'm trying to insall Adobe Photoshop CS3 on a new ASUS ASM11BB001O computer equipped with 64-bit Windows 7.  I use a "bundle" approach, first loading Photoshop 6, then upgrading with CS upgrade and then CS3 upgrade.  The installation goes smoothly until I

    I'm trying to install Adobe Photoshop CS3 on a new ASUS ASM11BB001O computer equipped with 64-bit Windows 7.  I use a "bundle" approach, first loading Photoshop 6, then upgrading with CS upgrade and then CS3 upgrade.  The installation goes smoothly until I add PS CS, and then it balks at the "accept" Adobe conditions screen.  I have two other (Gateway) computers with Windows 7, 64-bit, on both of which the PS-6, CS-CS3 pathway worked fine.  Any thoughts on how to get this working?  Thanks

    If your goal is to install and activate CS5 there is no need to install anything preceding it.  You will only need to have the serial number from the preceding version that you upgrade from (CS3 I guess).

  • My wifi goes down at least once a day and I have to unplug the time capsule and reboot it and then it works fine.  Any idea why this is happening/what I can do to fix it?

    My wifi goes down at least once a day and I have to unplug the time capsule and reboot it and then it works fine.  Any idea why this is happening/what I can do to fix it?

    I was having this problem while still using Mavericks -- it started after a Mavericks update last spring.  During the initial Yosemite beta runs over the summer, it seemed to be fixed, but after the official launch in October, I had all sorts of problems keeping connected.  Its gotten a little better, but still happens to at least one of my devices every day.  Weird that we still cannot figure out why the connection keeps dropping on some devices, but not others, and then the next day, one of the devices that didn't disconnect the previous day will disconnect, but the ones that did disconnect, stay connected.  It's just sloppy, poorly written software for technology that isn't working the way it should.  If you turn off Continuity and Handoff on all your devices, you will probably see that everything stays connected.  With those turned off on all devices, TC stayed connected to everything for over a month.  The day I turned Continuity back on, all the problems started again.  It had something to do with the bluetooth version being used, the wifi routine, and Apple's AirPlay technology not quite getting along with each other.

  • If I buy a mac with mountain lion and then upgrade to mavericks wil I get iWork for free, If I buy a mac with mountain lion and then upgrade to mavericks wil I get iWork for free

    If I buy a mac with mountain lion and then upgrade to mavericks will I get iWork for free.

    If you buy a new Mac with Mountain Lion, any included software is free and can be redownloaded from AppStore for that machine only. Some software only gets reinstalled if OS X (only) gets installed over itself to fix issues. See #8 Step here.
    ..Step by Step to fix your Mac
    If you upgrade to Mavericks usually only OS X itself is changed (sometimes the hidden User Library is also), all the  software (and user accounts) also carries over (compatible or not), and Apple's software is upgraded.
    So if your new Mountain Lion Mac comes with free iWork, then when you upgrade to Mavericks it will still be there.
    If your new Mountain Lion does not come with free iWork, then it won't magically appear for free if you upgrade to Mavericks.
    If you need a free Office suit, I suggest you look at the donationware LibreOffice.
    You will likely need to control key or right click to "Open" LibreOffice to approve through OS X's "Gatekeeper".
    You will need to manually update it also, as it's not on AppStore.
    https://www.libreoffice.org/
    Benefit of LibreOffice is it's completely cross-platform compatible, so you can share working files with Windows and Linux users, which you can't with iWork.
    You also should learn Microsoft Office when you have the funds, because it's standardized in the business world.

  • How works lync when I made a video conferences with someone in my same building?I want to understand how lyncs works, when I made video conferences with someone in my same building, if my call go to to server and then go to the person I´m calling. Or if L

    I want to understand how lyncs works, when I made video conferences with someone in my same building, if my call go to to server and then go to the person I´m calling.
    Or if Lync realizes that we are in the same building so it never leaves, so it don’t generate traffic. My concern is the bandwidth consumption.
    Please a I need the information.
    thanks

    In addition, you can refer to the following link about the media connection in different scenarios:
    http://www.shudnow.net/2010/12/06/lync-server-2010-port-ranges-and-audiomedia-negotiation/
    Note: Microsoft is providing this information as a convenience to you. The sites are not controlled by Microsoft. Microsoft cannot make any representations regarding the quality, safety, or suitability of any software or information found there. Please make
    sure that you completely understand the risk before retrieving any suggestions from the above link.
    Lisa Zheng
    TechNet Community Support

  • Is it possible to load an instructional DVD with several chapters onto my iMac and then somehow access the different chapters as needed remotely on my iPad?

    Is it possible to load an instructional DVD with several separate chapters onto my iMac and then somehow access the different chapters as needed remotely on my iPad?

    The "TDMS Open" node does more than open a file handle, it will load meta data (including file/group/channels' properties) and create index structures in ram for fast accessing any raw data in TDMS file. Thus, my advice is:
    1) You can save the efforts to write sub-VIs to preload properties of a TDMS file at least, since they are already kept in memory after the file is opened.
    2) Since index structures are presented, the performance to read data of any part in a tdms file will not be affected by the file size and the read performance might already satisfy your application. You can have a try.

  • I've can't open any applications on my Mac ! I tried to delete some files from safari (history) and then none of the apps including iphoto, safari, mail, facetime. I don't know how to fix it, help ? any idea ?

    I've can't open any applications on my Mac ! I tried to delete some files from safari (history) and then none of the apps including iphoto, safari, mail, facetime. I don't know how to fix it, help ? any idea ?

    Please read this whole message before doing anything.
    This procedure is a diagnostic test. It’s unlikely to solve your problem. Don’t be disappointed when you find that nothing has changed after you complete it.
    The purpose of the test is to determine whether the problem is caused by third-party software that loads automatically at startup or login, or by a peripheral device. 
    Disconnect all wired peripherals except those needed for the test, and remove all aftermarket expansion cards. Boot in safe mode and log in to the account with the problem. Note: If FileVault is enabled, or if a firmware password is set, or if the boot volume is a software RAID, you can’t do this. Ask for further instructions.
    Safe mode is much slower to boot and run than normal, and some things won’t work at all, including sound output andWi-Fi on certain iMacs. The next normal boot may also be somewhat slow.
    The login screen appears even if you usually log in automatically. You must know your login password in order to log in. If you’ve forgotten the password, you will need to reset it before you begin. Test while in safe mode. Same problem? After testing, reboot as usual (i.e., not in safe mode) and verify that you still have the problem. Post the results of the test.

  • When i turn on my macbook pro it has a black screen and just beeps quickly 3 times with a pause and then repeats.

    when i turn my macbook pro it has a black screen and it beeps 3 times in succession with a pause and then repeats the beeping and so on.

    If you replaced the Ram in your machine at any time, you may not have been aware of the fact that Apple computers have always been a little picky when it comes to 3rd party Ram.  Apple computers have always run very well on 2 different brands.
    Memory for iMac 2GB, 4GB, 8GB, 16GB, & now 32GB - OWC Certified RAM for Apple iMac with Lifetime Warranty
    This first link is from other world computing and none of us on these forums to my knowledge have heard of any bad ram from either Other World Computing
    or Crucial Ram.
    Crucial Ram
    The only difference I am aware of is that Crucial offers a download and will tell you exactly what Ram your computer is capable of using and the prices that are available.
    Resolving Kernel Panics
    HOPE THIS HELPS IN SOME WAY
    DON

  • I AM A CREATIVE CLOUD MEMBER FOR SOMETIME BUT NOW WHEN I LOGIN WITH THE CORRECT PASSWORD I STILL GET SIGNED OUT MESSAGE AND THEN WHEN TRIED THE SOLUTION GIVEN BY HELP THAT IS TO DELETE OPM.DB FILE OR SECOND SOLUTION INSTALL A FRESH CREATIVE CLOUD FOR DESK

    I AM A CREATIVE CLOUD MEMBER FOR SOMETIME BUT NOW WHEN I LOGIN WITH THE CORRECT PASSWORD I STILL GET SIGNED OUT MESSAGE AND THEN WHEN TRIED THE SOLUTION GIVEN BY HELP THAT IS TO DELETE OPM.DB FILE OR SECOND SOLUTION INSTALL A FRESH CREATIVE CLOUD FOR DESKTOP APP OR EVEN SOLUTION OF RUN OF IMSLIBREPLACER  IM STIILL NOT ABLE TO LOGIN TO MY CREATIVE CLOUD FOR DEKTOP APP . PLEASE HELP ME AS I NEED TO GET IN AND EXPLORE MORE OF MY DOWNLOADED S/W
    I HAVE TRIED ALL POSSIBLE SOLUTION BUT AM AMAZED HOW THIS IS HAPPENING TO ME.
    PLEASE PLEASE HELP ME .Creative Cloud Connection

    Hi Alfred,
    I would like to know the exact error message when you sign in, in the meanwhile please try the following steps assuming its Windows, let me know if its a MAC:
    1) Go to Start button>> Control panel>> Uninstall a program.
    2) Check if you see Browser safeguard there, if yes then uninstall it.
    3) Open Internet explorer>> Tools>> Internet options>> Connections>> Lan Settings>> and it should be like this.
    -Ankit

Maybe you are looking for

  • Report Not Working

    Hi Everyone, Installed Application Express and I am having some trouble in getting some basic reporting functionality working. Setup Tables: client Definition: Col1 = client_id, Col2 = client_name, Col3 = suburb I also created a sequence, client_seq.

  • Adobe Illustrator CS6 has stopped working on Windows 7

    I've seen a few posts about this and I stall haven't seen it stop or a fix that works. I use Illustrator any length of time (up and running just a few minutes till up for weeks on end) and as soon as I quit (either by File -> Exit, the X in the corne

  • Airport Problems after Security Update 2007-004

    Ever since I've installed Security Update 2007-004 my Airport connection has been dropping about every 15 to 30 minutes. Sometimes Airport will stay connected but will stop working until I renew my DHCP lease (I get the same IP though). When it drops

  • AV COMPONENT CABLE+VIDEO

    Hello, We have bought the Component AV Cable to be able to watch video and listen music from our ipod touch. We can listen our music from the Ipod Touch trough our blue ray system without any problem, choosing AUX option. We tryed to watch a movie an

  • 1) Compressor artifacts and 2) Processes not responding

    The whole reason I switched from Windows/Premier to Mac/Final Cut was to avoid broken software. I'm beginning to think the Mac is no better. Well, that's not entirely true. I think OS X is more stable than any version of windows but DVD Studio Pro 4.