Search found 49 matches

by Martin Honnen
Sat Apr 20, 2019 10:25 am
Forum: Feature Request
Topic: Querying JSON the XPath 3.1 way
Replies: 1
Views: 43

Querying JSON the XPath 3.1 way

In https://www.oxygenxml.com/doc/versions/21.0/ug-editor/topics/json-transforming.html, it is explained how to use XSLT or XQuery to transform JSON input and https://www.oxygenxml.com/doc/versions/21.0/ug-editor/topics/json-querying-xpath-xquery.html explains how to use "XPath" to select data from a...
by Martin Honnen
Sat Apr 13, 2019 1:10 pm
Forum: XSLT and FOP
Topic: formatting XPath expressions in XSLT 3 text templates
Replies: 1
Views: 144

formatting XPath expressions in XSLT 3 text templates

Using XML Editor 21.0, build 2019040204, I am struggling to get some nice formatting of XPath expressions in XSLT 3 text templates. For instance, imagine I have prototyped some XPath code in the XPath builder e.g. serialize(array { let $s := ('a', 'b', 'c', 'd') return for-each-pair($s[position() mo...
by Martin Honnen
Tue Feb 26, 2019 11:33 am
Forum: XQuery
Topic: Using XQuery 3.1 with output methods adpative or json
Replies: 3
Views: 676

Re: Using XQuery 3.1 with output methods adpative or json

Somehow I don't get it to work, even as you described it. I have created a new project to test it with <oXygen/> XML Editor 21.0, build 2019022207, there I now have an XQuery file simply returning an array literal declare namespace map = "http://www.w3.org/2005/xpath-functions/map"; declare namespac...
by Martin Honnen
Sun Feb 24, 2019 1:42 pm
Forum: XQuery
Topic: Using XQuery 3.1 with output methods adpative or json
Replies: 3
Views: 676

Using XQuery 3.1 with output methods adpative or json

Using the recent oXygen 21 release, I had hoped there is now a way to use XQuery 3.1 with any of the installed Saxon 9.8.0.12 engines (i.e. HE, PE, EE) to make use of XQuery 3.1 directives like declare namespace output = "http://www.w3.org/2010/xslt-xquery-serialization"; declare option output:metho...
by Martin Honnen
Sat Feb 23, 2019 6:33 pm
Forum: Feature Request
Topic: XPath 3.1 support
Replies: 1
Views: 182

XPath 3.1 support

Given that the current and latest (and probably last) version of XPath is 3.1 and not 3.0 I wonder why the XPath field and the XPath builder in oXygen 21 continue to only list 3.0 as the possible highest XPath value. It also seems that some XPath 3.1 language features like the string concatenation o...
by Martin Honnen
Fri Dec 14, 2018 4:41 pm
Forum: XSLT and FOP
Topic: XSLT and XPath syntax colouring
Replies: 1
Views: 422

XSLT and XPath syntax colouring

Is the use of the red color for the dot and comma (after 'source-node' :) in the code snippet <?xml version="1.0" encoding="UTF-8"?> <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:math="http://www.w3.org/2005/xpath-functions/math" e...
by Martin Honnen
Wed Oct 10, 2018 12:16 pm
Forum: XSLT and FOP
Topic: XSLT to select nodes dynamically
Replies: 1
Views: 676

Re: XSLT to select nodes dynamically

For cross-references you can use a key, to output the data you can use value-of and/or the string concatenation operator "||" in XSLT/XPath 3: <?xml version="1.0" encoding="UTF-8"?> <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xs="http://www.w3.org/2001/XMLSchema" version="...
by Martin Honnen
Fri Oct 05, 2018 9:45 pm
Forum: Feature Request
Topic: Provide Saxon 9.9 as a plugin
Replies: 2
Views: 727

Provide Saxon 9.9 as a plugin

Are there any plans to provide Saxon 9.9 EE as a plugin for oXygen 20.1 users, like you provided Saxon 9.8 EE as a plugin in earlier versions of oXygen that used 9.7 as its main XSLT/XQuery processor?
by Martin Honnen
Thu Oct 04, 2018 6:42 pm
Forum: XSLT and FOP
Topic: Count and Sum based on condition - Trailer record
Replies: 1
Views: 695

Re: Count and Sum based on condition - Trailer record

Is that the same condition you have in <xsl:if test="wd:Deduction/wd:ID[@wd:type='Deduction_Code'] != '401K-T'"> ? Seem you simply want to create a global variable <xsl:variable name="records" select="wd:Report_Data/wd:Report_Entry/wd:Payroll_Result_Lines[wd:Deduction/wd:ID[@wd:type='Deduction_Code'...
by Martin Honnen
Wed Sep 26, 2018 4:10 pm
Forum: General XML Questions
Topic: How do I format xslt address for xml
Replies: 2
Views: 832

Re: How do I format xslt address for xml

Assuming you use XSLT 2 or 3 (e.g. with Saxon 9) you can use

Code: Select all


<AddressFullText>
<xsl:value-of select="AddressLine1, AddressLine2, AddressLine3, AddressLine4" separator="&#10;"/>
</AddressFullText>
by Martin Honnen
Tue Sep 18, 2018 7:27 pm
Forum: Feature Request
Topic: Supporting content completion/tooltip helper for XPath 3.1 functions that take JSON map, like the transform function
Replies: 3
Views: 937

Re: Supporting content completion/tooltip helper for XPath 3.1 functions that take JSON map, like the transform function

In what context are you using XPath 3.1? Is it while editing XQuery (3.1) or is this in another context (e.g. XPath/XQuery Builder)? I use it inside XSLT 3 stylesheets as well as in XQuery 3.1 files, but often I try to experiment or prototype stuff in the XPath/XQuery builder (where I then select o...
by Martin Honnen
Mon Sep 17, 2018 11:08 pm
Forum: XSLT and FOP
Topic: XSLT: Generate ID
Replies: 5
Views: 1070

Re: XSLT: Generate ID

I have another question regarding parent-child relationships. How can I achieve the injection of <ParenId> in <Parent> and <Child> sections in the example below? <Root> <Parent> <ParentId>1</ParentId> <ParentName>P1</ParentName> <Child> <ChildId>1</ChildId> <ParentId>1</ParentId> <ChildName>C1</Chi...
by Martin Honnen
Fri Sep 14, 2018 4:53 pm
Forum: XSLT and FOP
Topic: XSLT: Generate ID
Replies: 5
Views: 1070

Re: XSLT: Generate ID

So what kind of ID are you looking for? In general assuming you have a version of oXygen that supports XSLT 3 all such stylesheet that need to perform a transformation of some nodes but keep the rest of the document unchanged would start with <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Tra...
by Martin Honnen
Fri Sep 14, 2018 1:32 pm
Forum: XSLT and FOP
Topic: adding and remove element in text node
Replies: 1
Views: 580

Re: adding and remove element in text node

So what are the exact rules for the transformation, even if you can't express them as XSLT? For the first sample you simply want to map the "s" element to a "p" and then wrap all the contents of the "s" element additionally into a "t" element which can be easily done with <xsl:template match="s"> <p...
by Martin Honnen
Thu Sep 13, 2018 11:15 pm
Forum: Feature Request
Topic: Supporting content completion/tooltip helper for XPath 3.1 functions that take JSON map, like the transform function
Replies: 3
Views: 937

Supporting content completion/tooltip helper for XPath 3.1 functions that take JSON map, like the transform function

With previous versions of XPath, oXygen has nice support for displaying argument types of a function call in XPath expressions in a tooltip (https://www.oxygenxml.com/doc/versions/20.1/ug-editor/topics/xpath-tooltip-helper.html) but with the arrival of maps https://www.w3.org/TR/xpath-31/#id-maps in...
by Martin Honnen
Tue Aug 21, 2018 12:55 pm
Forum: XQuery
Topic: Exact license/version of Saxon 9.8 EE for XQuery in oXygen 20.1, general EE or only EE-Q
Replies: 1
Views: 833

Exact license/version of Saxon 9.8 EE for XQuery in oXygen 20.1, general EE or only EE-Q

Based on https://saxonica.plan.io/boards/3/topics/7281 I am wondering what kind of licence the Saxon EE 9.8.0.12 XQuery processor used in oXygen 20.1 has, it is the general EE license that according to http://www.saxonica.com/products/feature-matrix-9-8.xml supports schema-aware XSLT as well XQuery ...
by Martin Honnen
Mon Aug 20, 2018 11:24 am
Forum: XQuery
Topic: Support for data URIs in XQuery with Saxon in oXygen
Replies: 4
Views: 1029

Re: Support for data URIs in XQuery with Saxon in oXygen

Thanks for your answer and the explanations so far. The XQuery code let $query as xs:string := 'xquery version "3.1"; module namespace foo = "http://example.com/foo"; declare function foo:f1() as xs:string { "test" };', $module as map(*) := load-xquery-module('http://example.com/foo', map { 'locatio...
by Martin Honnen
Sun Aug 19, 2018 9:37 pm
Forum: XQuery
Topic: Support for data URIs in XQuery with Saxon in oXygen
Replies: 4
Views: 1029

Support for data URIs in XQuery with Saxon in oXygen

To find out whether I can use XQuery that generates XQuery code and load/run it with the W3C standard function https://www.w3.org/TR/xpath-functions/#func-load-xquery-module I tested whether I can use data URIs https://en.wikipedia.org/wiki/Data_URI_scheme inside of XQuery or XSLT. To my surprise th...
by Martin Honnen
Mon Mar 26, 2018 3:53 pm
Forum: Feature Request
Topic: xsl:template name="xsl:initial-template" completion/suggestion
Replies: 2
Views: 1199

xsl:template name="xsl:initial-template" completion/suggestion

Now that oXygen 20 uses Saxon 9.8 with XSLT 3 support as the default XSLT engine it might be nice to have any <xsl:template name="xsl: or maybe only <xsl:template name="xsl:i autocompleted/suggested as <xsl:template name="xsl:initial-template" as that is now the default name for called template styl...
by Martin Honnen
Fri Mar 16, 2018 6:21 pm
Forum: XSLT and FOP
Topic: Running Saxon 9.8 EE in oXygen 20 with streaming disabled
Replies: 1
Views: 899

Running Saxon 9.8 EE in oXygen 20 with streaming disabled

I am exploring how to use Saxon 9.8 EE in oXygen 20 with stylesheets that use streaming. As using streaming is a new feature that is difficult to understand and requires redeveloping your XSLT skill set and as furthermore sometimes Saxon gives different results when using streaming compared when not...
by Martin Honnen
Tue Jan 09, 2018 10:58 pm
Forum: XSLT and FOP
Topic: Is there a way to enable XPath content completion in text templates in XSLT 3.0?
Replies: 6
Views: 2158

Re: Is there a way to enable XPath content completion in text templates in XSLT 3.0?

Should I now get variable/function name completion in text value templates? I have tried with oXygen XML Editor 19.1, build 2017121318, but it doesn't seem to be implemented, for instance when I use an XSLT 3 stylesheet with expand-text="yes" on the root element and create a literal result element w...
by Martin Honnen
Thu Dec 21, 2017 3:59 pm
Forum: XQuery
Topic: Uncommenting code when writing XQuery
Replies: 2
Views: 1429

Re: Uncommenting code when writing XQuery

I agree that using an XML comment with <root> <!--<foo>a</foo>--> <bar>1</bar> </root> is also an option a user editing XQuery might want or expect with the "Toggle comment" feature. On the other hand, I for sure was looking for a way for the editor to assist me in commenting out that element and no...
by Martin Honnen
Thu Dec 21, 2017 11:42 am
Forum: XQuery
Topic: Uncommenting code when writing XQuery
Replies: 2
Views: 1429

Uncommenting code when writing XQuery

Suppose I write an XQuery where I first have e.g. > <root> <foo>a</foo> <bar>1</bar> </root> and then decide to comment out the "foo" element node by selecting it with the mouse and using the context menu in XML Editor 19.1, build 2017121318, "toggle comment", then oXygen gives me <root> (:<foo>a</f...
by Martin Honnen
Mon Oct 16, 2017 2:32 pm
Forum: XQuery
Topic: Can't format XQuery with group by clause using ":="
Replies: 2
Views: 1618

Can't format XQuery with group by clause using ":="

I have the following as an ".xq" file in oXygen XML Editor 19.1, build 2017092911 for $item in Base/Item group by $id := $item/Id order by $id return <Item> <Id>{$id}</Id> {for $marked in $item[Mark] group by $mark := $marked/Mark return <Marked name="{$mark}"> {sum($marked/Qty)} </Marked> } <Total>...
by Martin Honnen
Tue Oct 03, 2017 3:59 pm
Forum: XSLT and FOP
Topic: Using XSLT 3.0 and streamable default mode with Saxon 9.7 EE as external plugin
Replies: 10
Views: 3524

Re: Using XSLT 3.0 and streamable default mode with Saxon 9.7 EE as external plugin

Updating didn't seem to find a new version but I uninstalled the existing version and then looked for available plugins which offered me that 19.1 version and now with that installed and another restart the streamed processing with a streamable mode finally works without any warning. That's great, n...
by Martin Honnen
Sun Oct 01, 2017 12:57 pm
Forum: XSLT and FOP
Topic: Using XSLT 3.0 and streamable default mode with Saxon 9.7 EE as external plugin
Replies: 10
Views: 3524

Re: Using XSLT 3.0 and streamable default mode with Saxon 9.7 EE as external plugin

I have installed oXygen 19.1 and tried again whether streaming works, I continue to get the warning Engine name: Saxon-EE 9.8.0.4 (External) Severity: warning Description: The unnamed mode is streamable, but the input is not supplied as a stream with an XSLT 3.0 stylesheet and a streamable default m...
by Martin Honnen
Sun Jul 30, 2017 11:15 am
Forum: XSLT and FOP
Topic: Using XSLT 3.0 and streamable default mode with Saxon 9.7 EE as external plugin
Replies: 10
Views: 3524

Re: Using XSLT 3.0 and streamable default mode with Saxon 9.7 EE as external plugin

I have just tried to use an XSLT 3.0 stylesheet with streaming in oXygen 19 (2017062918) with the latest version of the Saxon 9.8 plugin (9.8.0.3), however, I still get a warning Engine name: Saxon-EE 9.8.0.3 (External) Severity: warning Description: is streamable, but the input is not supplied as a...
by Martin Honnen
Tue Jun 13, 2017 5:04 pm
Forum: Common Problems
Topic: Not able to start multiple instances of oXygen
Replies: 5
Views: 1332

Re: Not able to start multiple instances of oXygen

Thanks, editing and using the .bat works fine to open multiple instances. Is there a way to call the .bat passing in a project file to open that particular project?
by Martin Honnen
Tue Jun 13, 2017 1:24 pm
Forum: XSLT and FOP
Topic: Is there a way to edit/change the built-in schema for XSLT 3.0 content completion?
Replies: 2
Views: 1150

Is there a way to edit/change the built-in schema for XSLT 3.0 content completion?

I have run into problems using the XSLT 3.0 content completion in oXygen 19, when inserting an xsl:merge-source element it offers me attributes for-each-stream and for-each-item, it seems that for-each-stream was defined in earlier versions of the XSLT 3.0 draft but has been renamed since the latest...
by Martin Honnen
Mon Jun 12, 2017 8:33 pm
Forum: Common Problems
Topic: Not able to start multiple instances of oXygen
Replies: 5
Views: 1332

Not able to start multiple instances of oXygen

I would like to start multiple instances of oXygen (version XML Editor 19.0, build 2017042020) on Windows 10, I have read https://www.oxygenxml.com/doc/versions/19.0/ug-editor/topics/custom-system-properties.html and https://www.oxygenxml.com/doc/versions/19.0/ug-editor/topics/set-parameters-for-app...