The function validates the given XMLType instance against the XML schema located at schema_url. The name of the current node of the XML entity should match top_element_name if it is specified.
The schema_url is optional for schema based instances: the default value is the URI of the associated schema of the instance. For non-schema based instances the schema_url is required, an error is signalled otherwise.
The function does not use or modify internal "validated" flag that is e.g. used by XMLType.schemaValidate(). It is true even if the given schema_url is equal to the URI of own schema of the instance.
The function returns 1 if the validation is passed, 0 if it is failed.
The example creates an XMLType instance that is a document with a single element node"bad" and tries to validate it against XMLschema "file://xmlschema/test0001/clean.xsd" that does not match actual content of the document. The call of isSchemaValid() returns zero indicating failed validation.
select XMLType('<bad />', 'file://xmlschema/test0001/clean.xsd').isSchemaValid() callret INTEGER _______________________________________________________________________________ 0 1 Rows. -- 00000 msec.