cancel
Showing results for 
Search instead for 
Did you mean: 

XML Query not working

Former Member
0 Kudos

Hi,

I saved data as xml out of sql query and when i execute it its working fine but when i try to map in a xml query it throwing an error as " org.xml.sax.SAXParseExecption: The Processing Instruction target matching " [xX][mM][IL]" is not allowed"

Can some one point me where i am doing wrong here.

Thanks,

Raveen

Accepted Solutions (0)

Answers (1)

Answers (1)

agentry_src
Active Contributor
0 Kudos

Are you using Namespaces? What are you trying to select or match? What does the xml look like?

Regards,

Mike

Former Member
0 Kudos

Hi Mike,

I have a query first from which i made out a xml data as "http://server:port/XMII/Illuminator?QueryTemplate=<Querypath>&Content-Type=text/xml" and saved the data as .xml and i want to map this xml data into a XML Query. I passed the xml path in a URL on xml query as WEB://ABC/XML/[Param.1] and passed the saved xml in a parameter. When i run the XML Query i get to see the error.

What i am trying to accomplish here is i dont want to use any Simulator here, once i have a XML Query i want this to be included in a .swf file.

Thanks,

Raveen

agentry_src
Active Contributor
0 Kudos

What version of MII are you using?

If you are saving the file to MII, you may need to add the folder "WEB" in your url when referencing the file. Also check to make sure the .xml is being added to the end of the file. By default content with the extension of .xml is automagically put into the WEB folder under your project.

You may also want to save the file as DB:// or Server:// instead of Web:// to see if that affects your ability to retrieve the contents. Web is typically used when you are publishing and not if you are just storing a file on NW (via the workbench/MII).

Good luck,

Mike

Edited by: Michael Appleby on Mar 1, 2011 4:16 PM

Former Member
0 Kudos

Mike,

below is the XML data

<?xml version="1.0" encoding="UTF-8" ?>

<Rowsets DateCreated="2011-02-25T12:04:57" EndDate="2011-02-25T12:04:57" StartDate="2011-02-25T12:03:57" Version="12.1.7 Build(47)">

<Rowset>

<Columns>

<Column Description="Name" MaxRange="1" MinRange="0" Name="Name" SQLDataType="12" SourceColumn="Name" />

<Column Description="Id" MaxRange="1" MinRange="0" Name="Id" SQLDataType="4" SourceColumn="Id" />

</Columns>

<Row>

<Name>Pumps</Name>

<Id>2</Id>

</Row>

<Row>

<Name>Blenders</Name>

<Id>3</Id>

</Row>

<Row>

<Name>Packing</Name>

<Id>4</Id>

</Row>

<Row>

<Name>Furnaces</Name>

<Id>35</Id>

</Row>

<Row>

<Name>AirCompressors</Name>

<Id>36</Id>

</Row>

</Rowset>

</Rowsets>

As mentioned by you everything seems to in place, i made sure to add WEB://<PATH> in URL.

And i have another doubt, is there a way to simulate the data from databases, say i have a historian and i want the data which is stored in sql tables to be added to the historian.

Thanks,

Raveen

Edited by: raveensap on Mar 1, 2011 4:57 PM

jcgood25
Active Contributor
0 Kudos

The db, server, and web prefixes are used inside BLS. For your XMLQuery template you can simply use a relative path like:

/XMII/CM/ProjectName/Folder/File.xml

You can use the Copy Link option from the catalog tree on the xml file you've saved and paste it into your xml query, then strip off the http://server:port portion.

Another option is to test the xml file from the WB and copy the necessary portion from the browser.

Former Member
0 Kudos

Jeremy,

I am not sure what was the problem earlier with loading XML,I have renamed the xml and tried executing it then it worked.

Thanks all for the help.

Raveen