XmlManager::prepare |
![]() ![]() |
#include <DbXml.hpp>XmlQueryExpression XmlManager::prepare(const std::string &xquery, XmlQueryContext &context)
XmlQueryExpression XmlManager::prepare(XmlTransaction &txn, const std::string &xquery, XmlQueryContext &context)
Compile an XQuery expression into an XmlQueryExpression object. You can then run the XQuery expression repeatedly using XmlQueryExpression::execute.
Use this method to compile and evaluate XQuery expressions against your XmlContainer and XmlDocument objects any time you want to evaluate the expression more than once.
Note that the scope of the query provided here can be restricted using one of the XQuery navigational functions. For example:
"collection('mycontainer.dbxml')/foo"
or:
"doc('dbxml:/mycontainer.dbxml/mydoc.xml')/foo/@attr1='bar'"
The scope of a query can also be controlled by passing an appropriate contextItem object to XmlQueryExpression::execute.
Parameters
![]() ![]() |
Copyright (c) 1996-2009 Oracle. All rights reserved.