You can access an external document using the Adaptive Server XQL query function, which both parses and queries XML documents.
Pass the XML document to the XQL parser as an InputStream. You can use the class URLProcess to pass the XML document to either the XQL parse method or the XQL query method.
The class URLProcess is available on
$SYBASE/ASE-12_5/sample/JavaSql for UNIX environments
%SYBASE\ASE-12_5\sample\JavaSql for NT environments