Project

Profile

Help

Bug #6605 ยป compileXQueryFromStringTest3.py

Martin Honnen, 2024-12-07 14:38

 
from saxonche import *

from pathlib import Path

xquery1 = '"Static base uri : " || static-base-uri()'

with PySaxonProcessor() as saxon_proc:
print(saxon_proc.version)

xqueryProcessor = saxon_proc.new_xquery_processor()

workingDirPath = str(Path.cwd().absolute())

print(workingDirPath)

xqueryProcessor.set_cwd(workingDirPath)

result = xqueryProcessor.run_query_to_string(query_text=xquery1)

print(result)
    (1-1/1)