Validate and update a XML document with rules
Hi,
In my project work, I am thinking about using oracle rules BRMS (business rule management system) to validate certain rules on xml document.
Since I am new to the oracle rules, I want to know the feasibility of doing this with oracle rules.
I have a specific question...
I have XML documents that are in different schema versions. these schema are fixed but can add them in future as well.
I have two things to do:
1. transform a given XML document (in a one version) to another version
2. Validate the new XML document against the rules defined in the oracle business rules.
1.I can do the 1st task using XSLT transformation. But there is one challenge. Assume that there are new tags are added in the target schema compared to the source schema of the XML document.
If there are optional tags to be added, I want to know if oracle rules can be used for that. Because I want to make these things done without changing the code (java) or the application internals.
2. I have few questions on the 2nd issue. They are:
a) can I create rules in oracle BRMS based on target schemas. (or to all of them. If so, what needs to be done if I add a new schema in future. How to update the rules?)
b) is it possible to group the rules created above in oracle BRMS.
Lets say
R1, R2 rules are created against schema1 (version 1)
R3, R4, R5 rules are created against schema2 (version 2)
R6, R7 rules are created against schema3(version 3)
Can I create group R1, R2 and R6 rules in to a one group (G1) and R1, R2 and R7 rules in to another group (G2).
What are the APIs available in oracle BRMS to retrieve above defined groups at run time? (because business user can define any rules, ad group them at run time)
Once I have the groups, How can I validate a XML document against a group created above? What are the APIs available for this.
c) is it possible to add/update/delete tags to a XML document based on rules in oracle BRMS? if so, how?
appreciate your valuable feedback on this..
Hi Hareendra,
I think you should post your question in this other forum:
Forum Home » SOA & Process Management » SOA Suite
Oracle Business Rules is a component used in SOA Suite
Regards!
Jorge
Similar Messages
-
Updating a XML document with a processing instruction
Greetings Guru's
I have a fully functional XML database solution for our new system. The only thing left is for me to update a xml document in the database with a processing instruction to find the style sheet (JAXB strips it out when the XML must go back into the database).
I can update complete nodes and node elements in the xml document using updateXML in a regular update statement, but I do not know how to add the following processing instruction to my documents.
<?xml-stylesheet type="text/xsl" href="/RASWEB/JIT_REPORT.xslt"?>
[pre]
Thanks in advance
DerrickSQL> var xmltext varchar2(4000)
SQL> --
SQL> begin
2 :xmlText := '<Hello>World</Hello>';
3 end;
4 /
PL/SQL procedure successfully completed.
SQL> drop table t
2 /
drop table t
ERROR at line 1:
ORA-00942: table or view does not exist
SQL> create table t of xmltype
2 /
Table created.
SQL> set long 10000
SQL> --
SQL> insert into t values (xmltype(:xmltext))
2 /
1 row created.
SQL> select *
2 from t
3 /
SYS_NC_ROWINFO$
<Hello>World</Hello>
SQL> update t set object_value = updateXML
2 (
3 object_value,
4 '/',
5 xmlconcat
6 (
7 xmlpi("xml-stylesheet",'type="text/xsl" href="/RASWEB/JIT_REPORT.xslt"'),
8 object_value
9 )
10 )
11 /
1 row updated.
SQL> select * from t
2 /
SYS_NC_ROWINFO$
<?xml-stylesheet type="text/xsl" href="/RASWEB/JIT_REPORT.xslt"?>
<Hello>World</Hello>
SQL> -
How to parse an XML document with oracle8i
Has anyone a good link or an example how to decode and store an XML document into an oracle8i database.
I' ve found only good things for oracle9i.
Thank you
RogerHere is an example of parsing xml taken fro Oracle8i 8.1.7 xdk.
This one uses external OS files to pase, but could be easily converted to
use CLOB or VARCHAR2 string for parsing XML documents.
IF you wanted to use CLOB to store and manipulate xml documents you can use XMLParser and XMLDom
packages along with the DBMS_LOB package to do that.
-- This file demonstates a simple use of the parser and DOM API.
-- The XML file that is given to the application is parsed and the
-- elements and attributes in the document are printed.
-- The use of setting the parser options is demonstrated.
set serveroutput on;
create or replace procedure domsample(dir varchar2, inpfile varchar2,
errfile varchar2) is
p xmlparser.parser;
doc xmldom.DOMDocument;
-- prints elements in a document
procedure printElements(doc xmldom.DOMDocument) is
nl xmldom.DOMNodeList;
len number;
n xmldom.DOMNode;
begin
-- get all elements
nl := xmldom.getElementsByTagName(doc, '*');
len := xmldom.getLength(nl);
-- loop through elements
for i in 0..len-1 loop
n := xmldom.item(nl, i);
dbms_output.put(xmldom.getNodeName(n) || ' ');
end loop;
dbms_output.put_line('');
end printElements;
-- prints the attributes of each element in a document
procedure printElementAttributes(doc xmldom.DOMDocument) is
nl xmldom.DOMNodeList;
len1 number;
len2 number;
n xmldom.DOMNode;
e xmldom.DOMElement;
nnm xmldom.DOMNamedNodeMap;
attrname varchar2(100);
attrval varchar2(100);
begin
-- get all elements
nl := xmldom.getElementsByTagName(doc, '*');
len1 := xmldom.getLength(nl);
-- loop through elements
for j in 0..len1-1 loop
n := xmldom.item(nl, j);
e := xmldom.makeElement(n);
dbms_output.put_line(xmldom.getTagName(e) || ':');
-- get all attributes of element
nnm := xmldom.getAttributes(n);
if (xmldom.isNull(nnm) = FALSE) then
len2 := xmldom.getLength(nnm);
-- loop through attributes
for i in 0..len2-1 loop
n := xmldom.item(nnm, i);
attrname := xmldom.getNodeName(n);
attrval := xmldom.getNodeValue(n);
dbms_output.put(' ' || attrname || ' = ' || attrval);
end loop;
dbms_output.put_line('');
end if;
end loop;
end printElementAttributes;
begin
-- new parser
p := xmlparser.newParser;
-- set some characteristics
xmlparser.setValidationMode(p, FALSE);
xmlparser.setErrorLog(p, dir || '/' || errfile);
xmlparser.setBaseDir(p, dir);
-- parse input file
xmlparser.parse(p, dir || '/' || inpfile);
-- get document
doc := xmlparser.getDocument(p);
-- Print document elements
dbms_output.put('The elements are: ');
printElements(doc);
-- Print document element attributes
dbms_output.put_line('The attributes of each element are: ');
printElementAttributes(doc);
-- deal with exceptions
exception
when xmldom.INDEX_SIZE_ERR then
raise_application_error(-20120, 'Index Size error');
when xmldom.DOMSTRING_SIZE_ERR then
raise_application_error(-20120, 'String Size error');
when xmldom.HIERARCHY_REQUEST_ERR then
raise_application_error(-20120, 'Hierarchy request error');
when xmldom.WRONG_DOCUMENT_ERR then
raise_application_error(-20120, 'Wrong doc error');
when xmldom.INVALID_CHARACTER_ERR then
raise_application_error(-20120, 'Invalid Char error');
when xmldom.NO_DATA_ALLOWED_ERR then
raise_application_error(-20120, 'Nod data allowed error');
when xmldom.NO_MODIFICATION_ALLOWED_ERR then
raise_application_error(-20120, 'No mod allowed error');
when xmldom.NOT_FOUND_ERR then
raise_application_error(-20120, 'Not found error');
when xmldom.NOT_SUPPORTED_ERR then
raise_application_error(-20120, 'Not supported error');
when xmldom.INUSE_ATTRIBUTE_ERR then
raise_application_error(-20120, 'In use attr error');
end domsample;
show errors; -
Open XML document with proper layout
Hi,
I created my own XML form and I have problem when accessing the document within "KM Content".
Indeed, when I click on the XML file generated by the XML Form it doesn't render it with the "Show" form but rather displays it as an usual XML document (with all its tags).
Hint:
I linked my iView to a custom CM repository. But, if I link my iView containing the XML Form to the out-of-the-box CM repository "/documents", it works fine.
What should I do to make this work?
Thanks in advance,
EricHi Eric,
in the Configuration under 'System Administration' -> 'System Configuration' -> 'Knowledge Management' -> 'Content Management' -> 'Repository Filters' you can find a filter named 'xmlforms_filter'. Some repositories are registered for this filter (in the standard e.g. documents). You should add your repositoriy here. After that the files in your repository should use the Show-form when being displayed.
Hope this helps
Karin -
Has anybody tried creating and validating a XML doc with XML Schema?
Hi,
Has anybody tried creating and validating a XML doc with XML Schema?With XMLBeans, an XML document may be created from and validated with an XML schema.
-
Please help; how to write XML document with JSP?
I try to write XML document with JSP...
But I got wrong results everytime.
The result is not XML file displayed in the browser,
but HTML file.
I even tried to use HTML special code for <, >, "
but still display as HTML file not XML file.
How to do this?
Thanks in advance. I put my codes below.
Sincerely,
Ted.
================
Here is code for the JSP (called stk.jsp):
<%@ page contentType="text/xml" %>
<%@ page import="bean.Stock" %>
<jsp:useBean id="portfolio" class="bean.Portfolio" />
<% java.util.Iterator pfolio = portfolio.getPortfolio();
Stock stock = null; %>
<?xml version="1.0" encoding="UTF-8"?>
<portfolio>
<% while (pfolio.hasNext())
stock = (Stock) pfolio.next(); %>
<stock>
<symbol>
<%=stock.getSymbol() %>
</symbol>
<name><%=stock.getName() %> </name>
<price><%=stock.getPrice() %> </price>
</stock>
<% } %>
</portfolio>
=================
Here is the code for bean.Stock:
package bean;
public class Stock implements java.io.Serializable
String symbol, name;
float price;
public Stock(String symbol, String name, float price)
this.symbol = symbol;
this.name = name;
this.price = price;
public String getSymbol()
return symbol;
public String getName()
return name;
public float getPrice()
return price;
===============
And here is bean.Portfolio:
package bean;
import java.util.Iterator;
import java.util.Vector;
public class Portfolio implements java.io.Serializable
private Vector portfolio = new Vector();
public Portfolio()
portfolio.addElement(new Stock("SUNW", "Sun Microsystem", 34.5f));
portfolio.addElement(new Stock("HWP", "Hewlett Packard", 15.15f));
portfolio.addElement(new Stock("AMCC", "Applied Micro Circuit Corp.", 101.35f));
public Iterator getPortfolio()
return portfolio.iterator();
}Hi
I'm not sure whta your query is but I tested your code as it is has been pasted and it seems to work fine. There is an XML output that I'm getting.
Keep me posted.
Good Luck!
Eshwar Rao
Developer Technical Support
Sun microsystems
http://www.sun.com/developers/support -
Please Vote if you find this to be helpful!
App-V PowerShell: Script to Query XenApp Servers for App-V Publishing Errors and Output an Excel Document with the Results
Just posted this to the wiki:
http://social.technet.microsoft.com/wiki/contents/articles/25323.app-v-powershell-script-to-query-xenapp-servers-for-app-v-publishing-errors-and-output-an-excel-document-with-the-results.aspxHi petro_jemes,
Just a little claritification, you need to add the value to the variable "[string]$ou", and also change the language in the variable "$emailbody" in the function "Get-ADUserPasswordExpirationDate".
I hope this helps. -
How to update the posted documents with Business Area wise
Dear experts
Please suggest me how to update the posted documents with Business Area wise
Ajeesh.s
Moderator message: please do more research before asking, show what you have done yourself when asking.
Edited by: Thomas Zloch on Nov 2, 2011 2:26 PMHi,
Select all your folders in Disco Administrator,ALT+ENTER to go to properties, then change the database from the default database to the remote database.
Hope that helps,
Rod West -
Problem when trying to load an XML document with DTD or XML SCHEMA
Hello
I have tried to load an XML document in Data Services, and I created the xsd file and Dtd file. (With altova xml spy software automatically) to import into SAP Data Services 3.2. .
In Data Services I created the dtd import file DTD and then called the XML file from the DTD (the xml file is validated vs the dtd file), and I could not read the xml correctly because it tells me that an ELEMENT called <item> expected joiners who did not come in the structure of import (dtd), but if the xml.
I understand that the document root is the label: CUSTOMER_FULL_2014, the data flow is as follows:CARGA_XML_CUSTOMER |
Turns out the joiners element is used to separate the xml elements are repeated, but is used at different levels. My idea is that the design will dtd second, or something I'm missing or is incorrectly stated.
Thank you.
xml
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
<?xml version="1.0" encoding="utf-8"?>
<CUSTOMER_FULL_2014>
<item>
<CUST_NO>202222</CUST_NO>
<ADDRESS>
<item>
<SHIP_TO>202222</SHIP_TO>
<NAME1>Henley.</NAME1>
<STREET>Vitacura #40</STREET>
<CITY>LIMA</CITY>
</item>
</ADDRESS>
<EQUIPMENT>
<item>
<EQUI_NO>81623</EQUI_NO>
</item>
<item>
<EQUI_NO>81633</EQUI_NO>
</item>
<item>
<EQUI_NO>81993</EQUI_NO>
</item>
<item>
<EQUI_NO>82003</EQUI_NO>
</item>
<item>
<EQUI_NO>82013</EQUI_NO>
</item>
<item>
<EQUI_NO>82103</EQUI_NO>
</item>
<item>
<EQUI_NO>82113</EQUI_NO>
</item>
<item>
<EQUI_NO>581203</EQUI_NO>
</item>
<item>
<EQUI_NO>900003-EMER</EQUI_NO>
</item>
<item>
<EQUI_NO>9000033-STOCK</EQUI_NO>
</item>
</EQUIPMENT>
<STORAGE_LOC>
<item>
<STOR_LOC_NO>0001</STOR_LOC_NO>
<DESCRIPTION>01 Parts Center</DESCRIPTION>
</item>
<item>
<STOR_LOC_NO>0056</STOR_LOC_NO>
<DESCRIPTION>56 henley</DESCRIPTION>
</item>
</STORAGE_LOC>
</item>
<item>
<CUST_NO>2007933434343</CUST_NO>
<ADDRESS>
<item>
<SHIP_TO>2007933434343</SHIP_TO>
<NAME1>Campos de Almacenaje SA</NAME1>
<STREET>Calacoto2, Calle 1</STREET>
<HOUSE_NO>Piso 1</HOUSE_NO>
<CITY>La Paz</CITY>
</item>
</ADDRESS>
<EQUIPMENT>
<item>
<EQUI_NO>90000-EMER</EQUI_NO>
</item>
<item>
<EQUI_NO>90000333-STOCK</EQUI_NO>
</item>
</EQUIPMENT>
<STORAGE_LOC>
<item>
<STOR_LOC_NO>00012</STOR_LOC_NO>
<DESCRIPTION>01 Parts Center</DESCRIPTION>
</item>
<item>
<STOR_LOC_NO>0056</STOR_LOC_NO>
<DESCRIPTION>56 henley</DESCRIPTION>
</item>
</STORAGE_LOC>
</item>
<item>
<CUST_NO>200801333</CUST_NO>
<ADDRESS>
<item>
<SHIP_TO>200801333</SHIP_TO>
<NAME1>CONSTRUCTORA SA.</NAME1>
<STREET>Ruta Panamericana Km 100</STREET>
<CITY>San Antonio 23</CITY>
</item>
</ADDRESS>
<EQUIPMENT>
<item>
<EQUI_NO>1507933</EQUI_NO>
</item>
<item>
<EQUI_NO>1509733</EQUI_NO>
</item>
<item>
<EQUI_NO>90000-EMER</EQUI_NO>
</item>
<item>
<EQUI_NO>90000333-STOCK</EQUI_NO>
</item>
</EQUIPMENT>
<STORAGE_LOC>
<item>
<STOR_LOC_NO>0001</STOR_LOC_NO>
<DESCRIPTION>01 Parts Center</DESCRIPTION>
</item>
<item>
<STOR_LOC_NO>0056</STOR_LOC_NO>
<DESCRIPTION>56 henley</DESCRIPTION>
</item>
</STORAGE_LOC>
</item>
</CUSTOMER_FULL_2014>
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
ARCHIVO DTD CREADO (automáticamente con xml spy)
<?xml version="1.0" encoding="UTF-8"?>
<!-- DTD generado con XMLSpy v2014 rel. 2 (x64) (http://www.altova.com) -->
<!ELEMENT CITY (#PCDATA)>
<!ELEMENT item ((SHIP_TO, NAME1, STREET, HOUSE_NO?, CITY) | (CUST_NO, ADDRESS, EQUIPMENT, STORAGE_LOC) | (STOR_LOC_NO, DESCRIPTION) | EQUI_NO)>
<!ELEMENT NAME1 (#PCDATA)>
<!ELEMENT STREET (#PCDATA)>
<!ELEMENT ADDRESS (item)>
<!ELEMENT CUST_NO (#PCDATA)>
<!ELEMENT EQUI_NO (#PCDATA)>
<!ELEMENT SHIP_TO (#PCDATA)>
<!ELEMENT HOUSE_NO (#PCDATA)>
<!ELEMENT EQUIPMENT (item+)>
<!ELEMENT DESCRIPTION (#PCDATA)>
<!ELEMENT STORAGE_LOC (item+)>
<!ELEMENT STOR_LOC_NO (#PCDATA)>
<!ELEMENT CUSTOMER_FULL_2014 (item+)>
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
The error of MONITOR Data Services
11676
5184
XML-240108
11-04-2014 17:34:16
|Data flow CARGA_XML_CUSTOMER|Reader READ MESSAGE customer OUTPUT(customer)
11676
5184
XML-240108
11-04-2014 17:34:16
An element named <item> present in the XML data input does not exist in the XML format used to set up this XML source in data
11676
5184
XML-240108
11-04-2014 17:34:16
flow <CARGA_XML_CUSTOMER>. Please validate your XML data.
11676
5184
XML-240307
11-04-2014 17:34:16
|Data flow CARGA_XML_CUSTOMER|Reader READ MESSAGE customer OUTPUT(customer)
11676
5184
XML-240307
11-04-2014 17:34:16
XML parser failed: See previously displayed error message.
The Error from Monitor
The metadata DTD
Thanks
JuanHi Juan Juan,
I generated a new XSD file using MS Visual Studio based on your XML file.
The empty spaces in the source is replaced with <Null> in the target table.
Here is the XSD:
<?xml version="1.0" encoding="utf-8"?>
<xs:schema attributeFormDefault="unqualified" elementFormDefault="qualified" xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xs:element name="CUSTOMER_FULL_20140207_033015_001">
<xs:complexType>
<xs:sequence>
<xs:choice maxOccurs="unbounded">
<xs:element name="CUST_NO" type="xs:unsignedInt" />
<xs:element name="ADDRESS">
<xs:complexType>
<xs:sequence>
<xs:element name="SHIP_TO" type="xs:unsignedInt" />
<xs:element name="NAME1" type="xs:string" />
<xs:element name="STREET" type="xs:string" />
<xs:element minOccurs="0" name="HOUSE_NO" type="xs:string" />
<xs:element name="CITY" type="xs:string" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="EQUIPMENT">
<xs:complexType>
<xs:sequence>
<xs:element maxOccurs="unbounded" name="EQUI_NO" type="xs:string" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="STORAGE_LOC">
<xs:complexType>
<xs:sequence>
<xs:choice maxOccurs="unbounded">
<xs:element name="STOR_LOC_NO" type="xs:unsignedByte" />
<xs:element name="DESCRIPTION" type="xs:string" />
</xs:choice>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:choice>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:schema>
For Source XML
<?xml version="1.0" encoding="utf-8"?>
<CUSTOMER_FULL_20140207_033015_001>
<CUST_NO>200530</CUST_NO>
<ADDRESS>
<SHIP_TO>903533</SHIP_TO>
<NAME1>HENLEY - PART MAQUINARIAS S.A.</NAME1>
<STREET>Dean Camilo # 148, San Carlos</STREET>
<CITY>LIMA</CITY>
</ADDRESS>
<EQUIPMENT>
<EQUI_NO>4442</EQUI_NO>
<EQUI_NO>8163</EQUI_NO>
<EQUI_NO>8199</EQUI_NO>
<EQUI_NO>8200</EQUI_NO>
<EQUI_NO>8201</EQUI_NO>
<EQUI_NO>8210</EQUI_NO>
<EQUI_NO>8211</EQUI_NO>
<EQUI_NO>58120</EQUI_NO>
<EQUI_NO>90000-EMERGENCY</EQUI_NO>
<EQUI_NO>90000-STOCK</EQUI_NO>
</EQUIPMENT>
<STORAGE_LOC>
<STOR_LOC_NO>0001</STOR_LOC_NO>
<DESCRIPTION>01 Parts Center</DESCRIPTION>
<STOR_LOC_NO>0056</STOR_LOC_NO>
<DESCRIPTION>56 HEN</DESCRIPTION>
</STORAGE_LOC>
<CUST_NO>200793</CUST_NO>
<ADDRESS>
<SHIP_TO>200793</SHIP_TO>
<NAME1>Minera San Cristobal S.A.</NAME1>
<STREET>Calacoto, Calle 90, Torre 2</STREET>
<HOUSE_NO>Piso 5</HOUSE_NO>
<CITY>La Paz</CITY>
</ADDRESS>
<EQUIPMENT>
<EQUI_NO>90000-EMERGENCY</EQUI_NO>
<EQUI_NO>90000-STOCK</EQUI_NO>
</EQUIPMENT>
<STORAGE_LOC>
<STOR_LOC_NO>0001</STOR_LOC_NO>
<DESCRIPTION>01 Parts Center</DESCRIPTION>
<STOR_LOC_NO>0056</STOR_LOC_NO>
<DESCRIPTION>56 HEN</DESCRIPTION>
</STORAGE_LOC>
<CUST_NO>200801</CUST_NO>
<ADDRESS>
<SHIP_TO>200801</SHIP_TO>
<NAME1>ISEMAR S.A.</NAME1>
<STREET>Ruta Km 28.45</STREET>
<CITY>Don Torcuato Paraguay</CITY>
</ADDRESS>
<EQUIPMENT>
<EQUI_NO>15079</EQUI_NO>
<EQUI_NO>15097</EQUI_NO>
<EQUI_NO>90000-EMERGENCY</EQUI_NO>
<EQUI_NO>90000-STOCK</EQUI_NO>
</EQUIPMENT>
<STORAGE_LOC>
<STOR_LOC_NO>0001</STOR_LOC_NO>
<DESCRIPTION>01 Parts Center</DESCRIPTION>
<STOR_LOC_NO>0056</STOR_LOC_NO>
<DESCRIPTION>56 HEN</DESCRIPTION>
</STORAGE_LOC>
</CUSTOMER_FULL_20140207_033015_001>
Output:
Regards,
Akhileshkiran. -
Creation of a XML Document with DTD entry
I am trying to create a XML file on the fly. I use the
NodeFactory to contruct a document (createDocument()). I have
then setStandalone("no") and setVersion("1.0"). when I try to
add a DOCTYPE node via appendChild( new XMLNode("test",
Node.DOCUMENT_TYPE_NODE)), I get a ClassCastException.
This is using the 1.0.1.1.0 xml parser.
What is the mechanism to add a node of this type? I noticed that
the NodeFactory did not have a machanism for creating a DOCTYPE
node.
nullNestor Dutko (guest) wrote:
: I am trying to create a XML file on the fly. I use the
: NodeFactory to contruct a document (createDocument()). I have
: then setStandalone("no") and setVersion("1.0"). when I try to
: add a DOCTYPE node via appendChild( new XMLNode("test",
: Node.DOCUMENT_TYPE_NODE)), I get a ClassCastException.
: This is using the 1.0.1.1.0 xml parser.
: What is the mechanism to add a node of this type? I noticed
that
: the NodeFactory did not have a machanism for creating a DOCTYPE
: node.
There is no mechanism to create a new DOCUMENT_TYPE_NODE object
via DOM APIs. The only way to get a DTD object is to parse the
DTD file or the XML file using the DOMParser, and then use the
getDocType() method. Note that new XMLNode("test",
Node.DOCUMENT_TYPE_NODE) does not create a DTD
object. It creates an XMLNode object with the type set to
DOCUMENT_TYPE_NODE, which infact should not be allowed. The
ClassCastException is raised because appendChild expects a DTD
object (based on the type).
Also, we do not do any validation while creating the DOM tree
using the DOM APIs. So setting the DTD in the Document will not
help in validating the DOM tree that is constructed. The only way
to validate an XML file is to parse the XML document using
DOMParser or SAXParser.
Oracle XML Team
http://technet.oracle.com
Oracle Technology Network
null -
Hi,
i'm new at this, so i need some help. I am developing web service that interacts with user over SOAP. User has to send xsd and web service has to create or update xml whitch is something like database. Is this posible?
Thanx,
Alan.With XMLBeans an XML document may be generated from a schema.
Refer to section
Creating New XML Instances from Schema
http://xmlbeans.apache.org/docs/2.0.0/guide/conGettingStartedwithXMLBeans.html -
How to search for a text node with a particular value in an xml document with labview
supposing i have the following xml document:
<head>
<book>
<bookname>zio</bookname>
<author>dan</author>
</book>
<book>
<bookname>the spear warrior</bookname>
<author>britney</author>
</book>
<book>
<bookname>the beard</bookname>
<author>derrick</author>
</book>
</head>
i want to search for the author of the book "the beard" using for example the V.I Get first match of labview to access the the node with value "the beard" and then use Get next sibling V.I and Get node text content to get get the author of this book..so my question is how do i write the xpath expression for Get first match so as to access the node with bookname "the beard" instantyly? am trying to minimise the use of loops because they increase the time duration,..thank you (NB:i dont want to use Get all Matched V.I because it obliges me to use a loop in order to access the name derrick and this increases the time duration for my v.i)
Solved!
Go to Solution.Since it's all text, why not use a real quick Match Pattern (or Regular Expression, but you don't need that much power here), see attached.
Cameron
To err is human, but to really foul it up requires a computer.
The optimist believes we are in the best of all possible worlds - the pessimist fears this is true.
Profanity is the one language all programmers know best.
An expert is someone who has made all the possible mistakes.
To learn something about LabVIEW at no extra cost, work the online LabVIEW tutorial(s):
LabVIEW Unit 1 - Getting Started
Learn to Use LabVIEW with MyDAQ
Attachments:
Two-stage match demo.vi 8 KB -
Update the FI document with the PO customer number
Hi,
Is it possible to update a header field or item line field of customer of the FI document with the PO customer number or sales document of PO (VBAK-VBELN) at the billing moment. I cannot do by standard substitution because the original field is not saved in the table BSEG or BKPF.
Thanks,
CeciliaIt can be done via substitution with exit.
You can configure your exit and then ABAPer can define the code for that exit in the copy of the program RGGBS000 assigned to the substitution in view V_T80D (Transaction SM30)
In ABAP code you can fetch the values from various tables.
Regards,
Gaurav -
XML-Document with special characters
Hallo
i have an oracle database with a table of XmlType.
Now i want to insert the following document:
<message>
<to>[email protected]</to>
<from>[email protected]</from>
<subject>Question</subject>
<body>über den Wolken</body>
</message>
The problem is the special character "ü" which is transformed to "??". Must i declare a special character set? If yes - where? In the XML-Document or in the Database? And how must i do this?
Thank you very much
cu
HeidiHallo Raghu,
when i insert the following by iSqlPlus in Internet Explorer (on a German WinXP):
insert into xml_table_test values (xmltype ('<message><to>[email protected]</to><from>[email protected]</from><subject>Question</subject><body>über den Wolken</body></message>')) /
a new page is displayed with the following:
Substitution Variables
Enter values for substitution variables in the script to execute:
Variable Value
uuml
and in the inputfield above Value i can insert something (in my case "ü" - i think)
But i want to insert the documents with webdav and then i can´t do this...
when i select this:
select * from nls_session_parameters
PARAMETER VALUE
NLS_LANGUAGE AMERICAN
NLS_TERRITORY AMERICA
NLS_CURRENCY $
NLS_ISO_CURRENCY AMERICA
NLS_NUMERIC_CHARACTERS .,
NLS_CALENDAR GREGORIAN
NLS_DATE_FORMAT DD-MON-RR
NLS_DATE_LANGUAGE AMERICAN
NLS_SORT BINARY
NLS_TIME_FORMAT HH.MI.SSXFF AM
NLS_TIMESTAMP_FORMAT DD-MON-RR HH.MI.SSXFF AM
NLS_TIME_TZ_FORMAT HH.MI.SSXFF AM TZR
NLS_TIMESTAMP_TZ_FORMAT DD-MON-RR HH.MI.SSXFF AM TZR
NLS_DUAL_CURRENCY $
PARAMETER VALUE
NLS_COMP BINARY
NLS_LENGTH_SEMANTICS BYTE
NLS_NCHAR_CONV_EXCP FALSE
it´s all american --> must i change this to German/Europe? How?
Thank you very much
cu
Heidi -
How do I add (or insert) a node into an XML document with JSTL?
Dear all,
I am trying to use JSTL to store some data from a form into XML. However, I have read many articles in JSTL and only found that it can only be, as far as those articles are concerned, used to "read" data from XML files, but not "write" to them.
Am I missing something in JSTL? Or, if I want to write to an XML file (e.g., insert a new node, or modify a node's data), will I have to write my own bean and then use <c:usebean />?
Thanks very much in advance.
Regards,
RobertJSTL is not a programming language in and of itself. It is intended to help you to write scriptlet free JSPs.
JSP pages (by one school of thought) are intended to function as the "View" in a Model-View-Controller architecture.
Being a view, JSP pages should be able to look at things - but not touch.
The standard pattern is to go to a servlet first, which invokes the logic, and then forwards to a JSP for rendering.
Editing XML by adding new nodes etc etc is thus a function of the java code layer - servlet/action whatever you want to call it.
Giving you the power to edit XML documents via JSTL (ie on a JSP page) takes away from purity of the MVC design.
Hence why they don't provide the tags for manipulating XML, and only provide the database tags with a disclaimer that they should only be used for prototypes/trivial apps!
JSTL is designed to replace scriptlet code on a JSP page.
It can replace 99% of scriptlet code. The other 1% shouldn't be on the JSP in the first place :-)
cheers,
evnafets
Maybe you are looking for
-
I have been trying to import music into Itunes for a few hours and no disc will open up. It won't even show the cd icon. It worked great just a few days ago but now that I have updated to the new version it doesn't seem to work. I am not a computer s
-
Moving configuration data from ECC to MDG
Hi, We are also in process of moving the configuration data from ECC (Ehp 5.0) to MDG Hub (Ehp 6.0), looking for the option copying tables in transport request and moving the transport request to MDG-C. Appreciate your suggestion or best practices on
-
I just downloaded an update Mac OS X 10.6.8 and everything got smaller; how do I enlargen it back to what it was?
-
Safari 2.0.3 & Acid Search - It still works - FYI
Just thought I would let fellow Acid Search Users know that Acid Search does still work with the latest Safari... You need to get rid of the Acid Search Package when installing the latest update (or it crashes Safari), but once the update is up and r
-
Customer hierarchy changes history
Hello, is it possible to see all changes done in a customer hierarchy (entry in CDHDR CDPOS tables for exemple) ? Thanks.