All posts tagged with 'XML'

Pretty print XML data within Oracle Databases

05-Jun-13

Just a short post without further explanation. Pretty printing xml in Oracle 10g and 11g differences quite a bit: 10g: SELECT XMLTYPE('<html><body><p>Hallo, Welt.</p></body></html>’).extract(’/’) FROM dual;select XMLTYPE(‘<html><body><p>Hallo, Welt.</p></body></html>’).extract(‘/’) from dual; 11g: SELECT XMLSERIALIZE(Document XMLTYPE('<html><body><p>Hallo, Welt.</p></body></html>’) AS CLOB INDENT SIZE = 2) FROM dual;select XMLSERIALIZE(Document XMLTYPE(‘<html><body><p>Hallo, Welt.</p></body></html>’) as CLOB INDENT SIZE = 2) from dual;

Read the complete article »

XML / XSD Schema validation on Mac OS X

16-Jan-09

I found no fancy graphical xml validator on OS X, but this isn’t a problem. OS X includes libxml which comes with xmllint. To validate a xml file against a schema: xmllint –noout –schema sitemap.xsd sitemap.xmlxmllint –noout –schema sitemap.xsd sitemap.xml

Read the complete article »

A fistfull of readers

23-Oct-07

After presenting a working InputStream on a ByteBuffer, i have to more readers for you out there. First, the StringBufferReader to efficient read data from a StringBuffer. One can use new java.io.StringReader(sb.toString()) but that would convert the whole StringBuffer (sb) to a string, loosing a whole lotta memory if the string is just big enough. […]

Read the complete article »