You can subscribe to this list here.
2001 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(31) |
Nov
(25) |
Dec
(33) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2002 |
Jan
(48) |
Feb
(62) |
Mar
(22) |
Apr
(29) |
May
(9) |
Jun
(45) |
Jul
(28) |
Aug
(41) |
Sep
(60) |
Oct
(96) |
Nov
(99) |
Dec
(70) |
2003 |
Jan
(98) |
Feb
(159) |
Mar
(164) |
Apr
(150) |
May
(143) |
Jun
(97) |
Jul
(184) |
Aug
(143) |
Sep
(207) |
Oct
(126) |
Nov
(159) |
Dec
(165) |
2004 |
Jan
(131) |
Feb
(229) |
Mar
(220) |
Apr
(212) |
May
(320) |
Jun
(223) |
Jul
(191) |
Aug
(390) |
Sep
(261) |
Oct
(229) |
Nov
(215) |
Dec
(184) |
2005 |
Jan
(221) |
Feb
(312) |
Mar
(336) |
Apr
(273) |
May
(359) |
Jun
(277) |
Jul
(303) |
Aug
(321) |
Sep
(256) |
Oct
(415) |
Nov
(428) |
Dec
(508) |
2006 |
Jan
(585) |
Feb
(419) |
Mar
(496) |
Apr
(296) |
May
(403) |
Jun
(404) |
Jul
(553) |
Aug
(296) |
Sep
(252) |
Oct
(416) |
Nov
(414) |
Dec
(245) |
2007 |
Jan
(354) |
Feb
(422) |
Mar
(389) |
Apr
(298) |
May
(397) |
Jun
(318) |
Jul
(315) |
Aug
(339) |
Sep
(253) |
Oct
(317) |
Nov
(350) |
Dec
(264) |
2008 |
Jan
(353) |
Feb
(313) |
Mar
(433) |
Apr
(383) |
May
(343) |
Jun
(355) |
Jul
(321) |
Aug
(338) |
Sep
(242) |
Oct
(206) |
Nov
(199) |
Dec
(279) |
2009 |
Jan
(327) |
Feb
(221) |
Mar
(280) |
Apr
(278) |
May
(237) |
Jun
(345) |
Jul
(322) |
Aug
(324) |
Sep
(676) |
Oct
(586) |
Nov
(735) |
Dec
(329) |
2010 |
Jan
(619) |
Feb
(424) |
Mar
(529) |
Apr
(241) |
May
(312) |
Jun
(554) |
Jul
(698) |
Aug
(576) |
Sep
(408) |
Oct
(268) |
Nov
(391) |
Dec
(426) |
2011 |
Jan
(629) |
Feb
(512) |
Mar
(465) |
Apr
(467) |
May
(475) |
Jun
(403) |
Jul
(426) |
Aug
(542) |
Sep
(418) |
Oct
(620) |
Nov
(614) |
Dec
(358) |
2012 |
Jan
(357) |
Feb
(466) |
Mar
(344) |
Apr
(215) |
May
(408) |
Jun
(375) |
Jul
(241) |
Aug
(260) |
Sep
(401) |
Oct
(461) |
Nov
(498) |
Dec
(294) |
2013 |
Jan
(453) |
Feb
(447) |
Mar
(434) |
Apr
(326) |
May
(295) |
Jun
(471) |
Jul
(463) |
Aug
(278) |
Sep
(525) |
Oct
(343) |
Nov
(389) |
Dec
(405) |
2014 |
Jan
(564) |
Feb
(324) |
Mar
(319) |
Apr
(319) |
May
(384) |
Jun
(259) |
Jul
(210) |
Aug
(219) |
Sep
(315) |
Oct
(478) |
Nov
(207) |
Dec
(316) |
2015 |
Jan
(222) |
Feb
(234) |
Mar
(201) |
Apr
(145) |
May
(367) |
Jun
(318) |
Jul
(195) |
Aug
(210) |
Sep
(234) |
Oct
(248) |
Nov
(217) |
Dec
(189) |
2016 |
Jan
(219) |
Feb
(177) |
Mar
(110) |
Apr
(91) |
May
(159) |
Jun
(124) |
Jul
(192) |
Aug
(119) |
Sep
(125) |
Oct
(64) |
Nov
(80) |
Dec
(68) |
2017 |
Jan
(156) |
Feb
(312) |
Mar
(386) |
Apr
(217) |
May
(89) |
Jun
(115) |
Jul
(79) |
Aug
(122) |
Sep
(100) |
Oct
(99) |
Nov
(129) |
Dec
(77) |
2018 |
Jan
(106) |
Feb
(78) |
Mar
(160) |
Apr
(73) |
May
(110) |
Jun
(160) |
Jul
(93) |
Aug
(92) |
Sep
(75) |
Oct
(147) |
Nov
(114) |
Dec
(97) |
2019 |
Jan
(141) |
Feb
(78) |
Mar
(158) |
Apr
(60) |
May
(123) |
Jun
(54) |
Jul
(44) |
Aug
(147) |
Sep
(117) |
Oct
(54) |
Nov
(74) |
Dec
(96) |
2020 |
Jan
(113) |
Feb
(125) |
Mar
(142) |
Apr
(57) |
May
(71) |
Jun
(99) |
Jul
(58) |
Aug
(81) |
Sep
(49) |
Oct
(50) |
Nov
(63) |
Dec
(37) |
2021 |
Jan
(37) |
Feb
(45) |
Mar
(39) |
Apr
(18) |
May
(14) |
Jun
(9) |
Jul
(44) |
Aug
(23) |
Sep
(13) |
Oct
(31) |
Nov
(13) |
Dec
(33) |
2022 |
Jan
(17) |
Feb
(8) |
Mar
(32) |
Apr
(7) |
May
(17) |
Jun
(7) |
Jul
(36) |
Aug
(29) |
Sep
(9) |
Oct
(20) |
Nov
(10) |
Dec
(1) |
2023 |
Jan
(30) |
Feb
(37) |
Mar
(23) |
Apr
(1) |
May
(14) |
Jun
(5) |
Jul
(3) |
Aug
(6) |
Sep
(5) |
Oct
(48) |
Nov
(4) |
Dec
(29) |
2024 |
Jan
(1) |
Feb
|
Mar
(21) |
Apr
(6) |
May
(16) |
Jun
(41) |
Jul
(11) |
Aug
(17) |
Sep
(16) |
Oct
(11) |
Nov
(3) |
Dec
(9) |
2025 |
Jan
(7) |
Feb
(7) |
Mar
(6) |
Apr
(6) |
May
(30) |
Jun
(8) |
Jul
(10) |
Aug
(4) |
Sep
|
Oct
|
Nov
|
Dec
|
From: Michael W. <wes...@ja...> - 2021-08-09 02:19:24
|
Oh, and one more thing about the counter module. You'll need to copy the *counters* file in your EXIST_DATA directory to any new instances you create. This is because it is NOT managed within the database itself, so not backed up or restored. But it should be fairly straightforward to create such a library module that is managed within the database. Take care. 2021年8月9日(月) 10:40 Michael Westbay <wes...@ja...>: > Hi Gary, > > See the "counter" module built into eXist. > > let $dummy := counter:create('file-ids') > let $new-file-path := xmldb:store("/db/docs", > concat(counter:next-value('file-ids'), '.xml'), $doc) > > let $dummy := counter:destroy('file-ids') > > > Hope this helps. > > Take care. > > > 2021年8月9日(月) 2:44 Gary via Exist-open <exi...@li...>: > >> Hi Guys, >> >> Is there an eXistDB sequence generator function I can use inside an >> XQuery? >> >> I would like to create documents from an XQuery along these lines. >> >> let $new-file-path := xmldb:store("/db/docs", >> concat(xmldb:sequence-generator(), '.xml'), $doc) >> >> I am looking for a way to safely set, reset and persist counters and >> create a series of unique document names from each time the query is run >> e.g. 1.xml, 2.xml 3.xml etc. >> >> Kind Regards >> Gary >> Solution Architect >> https://www.rapport.net >> https://assistive.care >> https://q.rip >> >> Rapport Network CIC >> Registered in Scotland: SC458540 >> _______________________________________________ >> Exist-open mailing list >> Exi...@li... >> https://lists.sourceforge.net/lists/listinfo/exist-open >> > > > -- > Michael Westbay > Writer/System Administrator > http://www.japanesebaseball.com/ > -- Michael Westbay Writer/System Administrator http://www.japanesebaseball.com/ |
From: Michael W. <wes...@ja...> - 2021-08-09 01:41:22
|
Hi Gary, See the "counter" module built into eXist. let $dummy := counter:create('file-ids') let $new-file-path := xmldb:store("/db/docs", concat(counter:next-value('file-ids'), '.xml'), $doc) let $dummy := counter:destroy('file-ids') Hope this helps. Take care. 2021年8月9日(月) 2:44 Gary via Exist-open <exi...@li...>: > Hi Guys, > > Is there an eXistDB sequence generator function I can use inside an XQuery? > > I would like to create documents from an XQuery along these lines. > > let $new-file-path := xmldb:store("/db/docs", > concat(xmldb:sequence-generator(), '.xml'), $doc) > > I am looking for a way to safely set, reset and persist counters and > create a series of unique document names from each time the query is run > e.g. 1.xml, 2.xml 3.xml etc. > > Kind Regards > Gary > Solution Architect > https://www.rapport.net > https://assistive.care > https://q.rip > > Rapport Network CIC > Registered in Scotland: SC458540 > _______________________________________________ > Exist-open mailing list > Exi...@li... > https://lists.sourceforge.net/lists/listinfo/exist-open > -- Michael Westbay Writer/System Administrator http://www.japanesebaseball.com/ |
From: Adam R. <ad...@ex...> - 2021-08-08 20:09:19
|
There is a small bug with the Mail Module in 5.3.0 that is now fixed. Expect a 5.4.0 very soon On Fri, 6 Aug 2021, 08:14 Michael Westbay, < wes...@ja...> wrote: > Hi All, > > I'm currently working on moving one of my servers to eXist 5.3.0. When I > went to 4.x a while back, the "http://exist-db.org/xquery/mail" module > was still included, but it appears to be missing in 5.3.0. > > Am I missing it somewhere? Did I install it separately? > > -- > Michael Westbay > Writer/System Administrator > http://www.japanesebaseball.com/ > _______________________________________________ > Exist-open mailing list > Exi...@li... > https://lists.sourceforge.net/lists/listinfo/exist-open > |
From: Adam R. <ad...@ex...> - 2021-08-08 19:42:55
|
Just to check do you want a sequence, or just a unique Id? On Sun, 8 Aug 2021, 19:44 Gary via Exist-open, < exi...@li...> wrote: > Hi Guys, > > Is there an eXistDB sequence generator function I can use inside an XQuery? > > I would like to create documents from an XQuery along these lines. > > let $new-file-path := xmldb:store("/db/docs", > concat(xmldb:sequence-generator(), '.xml'), $doc) > > I am looking for a way to safely set, reset and persist counters and > create a series of unique document names from each time the query is run > e.g. 1.xml, 2.xml 3.xml etc. > > Kind Regards > Gary > Solution Architect > https://www.rapport.net > https://assistive.care > https://q.rip > > Rapport Network CIC > Registered in Scotland: SC458540 > _______________________________________________ > Exist-open mailing list > Exi...@li... > https://lists.sourceforge.net/lists/listinfo/exist-open > |
From: Gary <ga...@ra...> - 2021-08-08 17:43:41
|
Hi Guys, Is there an eXistDB sequence generator function I can use inside an XQuery? I would like to create documents from an XQuery along these lines. let $new-file-path := xmldb:store("/db/docs", concat(xmldb:sequence-generator(), '.xml'), $doc) I am looking for a way to safely set, reset and persist counters and create a series of unique document names from each time the query is run e.g. 1.xml, 2.xml 3.xml etc. Kind Regards Gary Solution Architect https://www.rapport.net https://assistive.care https://q.rip Rapport Network CIC Registered in Scotland: SC458540 |
From: Christian A. <chr...@ge...> - 2021-08-07 10:23:48
|
That describes exactly my problem: Eventually, the server delivers self-closing <span/> tags, and the browsers put all siblings as children into the <span />. My fault was that everything was serialized as JSON with the whole HTML block as a single string value inside this JSON. Now I switched to split up my request to 2 requests: The first one is receiving the documents' metadata as JSON; the 2nd request is serializing its response as HTML5 - with correct <span></span> tags. That solved my problem. Thanks for all the support. Am 03.08.21 um 21:08 schrieb Craig Berry: > I had a similar problem. It boiled down to fn:serialize defaulting to XHTML output, where the self-closing tags are legal, but the browser was interpreting the content as HTML5 rather than XHTML. In HTML5 self-closing tags are illegal on non-void elements, and the browser handles the error by turning all following siblings into children, i.e., the self-closing tag is interpreted as an opening tag with an implicit closing tag at the end of the parent. Made quite a mess of my web page until I finally figured out what was happening. > > I solved the problem by forcing it to serialize as HTML5, adding something like the following as the options parameter to fn:serialize: > > <output:serialization-parameters xmlns:output="http://www.w3.org/2010/xslt-xquery-serialization"> > <output:method>html</output:method> > <output:version>5.0</output:version> > </output:serialization-parameters> > > In your case you might be able to do the equivalent in the serialization option at the top of your script. > > You might also be able to convince the browser that what it's getting is XHTML. It would need to see a header something like this: > > Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8 > > However, it seems that the media-type part of your serialization option should already be doing that, so I'm not sure why your browser isn't handling the XHTML. You could fire up the debugging tools in your browser and see what content type you're really getting in the page headers. > > I was not able to get the browser to recognize the XHTML content type in my case because it was a portion of the page getting rewritten via AJAX and the content type was application/json. Serializing to HTML5 before embedding the AJAX results in JSON solved the problem for me. > >> On Aug 3, 2021, at 12:24 PM, Christian Achter <chr...@ge...> wrote: >> >> Dear community, >> >> I have a problem with an XQuery script that calls an XSLT script to convert some XML from the eXist database to HTML. >> >> E.g. this XML >> >> <lb/> >> >> gets converted to this HTML >> >> <span class="br" data-lineNum="6"/> >> >> which is a self-closing <span /> tag. But <span> is not allowed to be a self-closing tag <span ... /> in HTML. Instead it should be <span ...></span> with no content, but the attributes as above. >> >> I tried several things. The XSLT is called from within an XQuery script, so I declared in this XQuery file: >> >> declare option exist:serialize "method=xhtml media-type=application/xhtml+html"; >> >> But still I get self-closing <span />-tags. >> >> How can I force the HTML part to be like this: >> >> <span class="br" data-lineNum="6"></span> >> >> ?? >> >> Thanks in advance and let me know if more information is needed. >> >> Kind regards >> Christian >> >> >> >> >> _______________________________________________ >> Exist-open mailing list >> Exi...@li... >> https://lists.sourceforge.net/lists/listinfo/exist-open > ________________________________________ > Craig A. Berry > > "... getting out of a sonnet is much more > difficult than getting in." > Brad Leithauser > |
From: Michael W. <wes...@ja...> - 2021-08-07 00:43:06
|
Hi Omar, THANK YOU! Reverting to JDK 1.8 brought back the http://exist-db.org/xquery/mail package with eXist 5.3.0. I hadn't expected the JDK to be the culprit. There must have been some big changes on the Java side while I wasn't looking. Nick - Changing to the JDK 1.8 version was the only change I made. Nothing more needed to be installed or changed. When I regenerated the XQuery Function Documentation, the mail module appeared as available. Take care. 2021年8月6日(金) 21:32 Omar Siam <Oma...@oe...>: > Are you trying to run exist-db on JDK 11? > One dependency of the mail module is no longer shipped by default with > JDK11. > So one solution may be to run with JDK 1.8. > After adding this dependency I could start existdb with the > extensions/modules/mail. > I did not use it though. > > > https://github.com/acdh-oeaw/exist/commit/1b668c61783fbab3a812435838b964e09f3a87fb > (the second patch) > > Am 06.08.21 um 08:39 schrieb Nick Sincaglia: > > This is quite a coincidence. I was just about to ask this same question. I > am also upgrading to the new eXist-db v5.3.0 as well and I am getting the > error "Could not initialize > class.org.exist.xquery.modules.mail.MailModule". > > I checked conf.xml and it is enabled. > <module uri="http://exist-db.org/xquery/mail" > <http://exist-db.org/xquery/mail> > class="org.exist.xquery.modules.mail.MailModule"/> > > Nick > > > On 8/6/21 1:13 AM, Michael Westbay wrote: > > Hi All, > > I'm currently working on moving one of my servers to eXist 5.3.0. When I > went to 4.x a while back, the "http://exist-db.org/xquery/mail" module > was still included, but it appears to be missing in 5.3.0. > > Am I missing it somewhere? Did I install it separately? > > -- > Michael Westbay > Writer/System Administrator > http://www.japanesebaseball.com/ > > > _______________________________________________ > Exist-open mailing list > Exi...@li... > https://lists.sourceforge.net/lists/listinfo/exist-open > -- Michael Westbay Writer/System Administrator http://www.japanesebaseball.com/ |
From: Nick S. <nsi...@nu...> - 2021-08-06 15:20:56
|
I just checked and I am using JDK 11. Can you point me to information on how to add this dependency? Nick On 8/6/21 10:12 AM, Michael Westbay wrote: > Hi Omar, > > I did upgrade my JVM to JDK 16. I'll give that a try. > > Thank you! > > > 2021年8月6日(金) 21:32 Omar Siam <Oma...@oe... > <mailto:Oma...@oe...>>: > > Are you trying to run exist-db on JDK 11? > One dependency of the mail module is no longer shipped by default > with JDK11. > So one solution may be to run with JDK 1.8. > After adding this dependency I could start existdb with the > extensions/modules/mail. > I did not use it though. > > https://github.com/acdh-oeaw/exist/commit/1b668c61783fbab3a812435838b964e09f3a87fb > <https://github.com/acdh-oeaw/exist/commit/1b668c61783fbab3a812435838b964e09f3a87fb> > (the second patch) > > Am 06.08.21 um 08:39 schrieb Nick Sincaglia: >> This is quite a coincidence. I was just about to ask this same >> question. I am also upgrading to the new eXist-db v5.3.0 as well >> and I am getting the error "Could not initialize >> class.org.exist.xquery.modules.mail.MailModule". >> >> I checked conf.xml and it is enabled. >> <module uri="http://exist-db.org/xquery/mail" >> <http://exist-db.org/xquery/mail> >> class="org.exist.xquery.modules.mail.MailModule"/> >> >> Nick >> >> >> On 8/6/21 1:13 AM, Michael Westbay wrote: >>> Hi All, >>> >>> I'm currently working on moving one of my servers to eXist >>> 5.3.0. When I went to 4.x a while back, >>> the "http://exist-db.org/xquery/mail >>> <http://exist-db.org/xquery/mail>" module was still included, >>> but it appears to be missing in 5.3.0. >>> >>> Am I missing it somewhere? Did I install it separately? >>> >>> -- >>> Michael Westbay >>> Writer/System Administrator >>> http://www.japanesebaseball.com/ <http://www.japanesebaseball.com/> > > _______________________________________________ > Exist-open mailing list > Exi...@li... > <mailto:Exi...@li...> > https://lists.sourceforge.net/lists/listinfo/exist-open > <https://lists.sourceforge.net/lists/listinfo/exist-open> > > > > -- > Michael Westbay > Writer/System Administrator > http://www.japanesebaseball.com/ <http://www.japanesebaseball.com/> > > > _______________________________________________ > Exist-open mailing list > Exi...@li... > https://lists.sourceforge.net/lists/listinfo/exist-open -- Nick Sincaglia President/Founder NueMeta, LLC Digital Media & Technology Phone: +1-630-303-7035 nsi...@nu... http://www.nuemeta.com Skype: nsincaglia |
From: Michael W. <wes...@ja...> - 2021-08-06 15:12:56
|
Hi Omar, I did upgrade my JVM to JDK 16. I'll give that a try. Thank you! 2021年8月6日(金) 21:32 Omar Siam <Oma...@oe...>: > Are you trying to run exist-db on JDK 11? > One dependency of the mail module is no longer shipped by default with > JDK11. > So one solution may be to run with JDK 1.8. > After adding this dependency I could start existdb with the > extensions/modules/mail. > I did not use it though. > > > https://github.com/acdh-oeaw/exist/commit/1b668c61783fbab3a812435838b964e09f3a87fb > (the second patch) > > Am 06.08.21 um 08:39 schrieb Nick Sincaglia: > > This is quite a coincidence. I was just about to ask this same question. I > am also upgrading to the new eXist-db v5.3.0 as well and I am getting the > error "Could not initialize > class.org.exist.xquery.modules.mail.MailModule". > > I checked conf.xml and it is enabled. > <module uri="http://exist-db.org/xquery/mail" > <http://exist-db.org/xquery/mail> > class="org.exist.xquery.modules.mail.MailModule"/> > > Nick > > > On 8/6/21 1:13 AM, Michael Westbay wrote: > > Hi All, > > I'm currently working on moving one of my servers to eXist 5.3.0. When I > went to 4.x a while back, the "http://exist-db.org/xquery/mail" module > was still included, but it appears to be missing in 5.3.0. > > Am I missing it somewhere? Did I install it separately? > > -- > Michael Westbay > Writer/System Administrator > http://www.japanesebaseball.com/ > > > _______________________________________________ > Exist-open mailing list > Exi...@li... > https://lists.sourceforge.net/lists/listinfo/exist-open > -- Michael Westbay Writer/System Administrator http://www.japanesebaseball.com/ |
From: Omar S. <Oma...@oe...> - 2021-08-06 12:31:31
|
Are you trying to run exist-db on JDK 11? One dependency of the mail module is no longer shipped by default with JDK11. So one solution may be to run with JDK 1.8. After adding this dependency I could start existdb with the extensions/modules/mail. I did not use it though. https://github.com/acdh-oeaw/exist/commit/1b668c61783fbab3a812435838b964e09f3a87fb (the second patch) Am 06.08.21 um 08:39 schrieb Nick Sincaglia: > This is quite a coincidence. I was just about to ask this same > question. I am also upgrading to the new eXist-db v5.3.0 as well and I > am getting the error "Could not initialize > class.org.exist.xquery.modules.mail.MailModule". > > I checked conf.xml and it is enabled. > <module uri="http://exist-db.org/xquery/mail" > class="org.exist.xquery.modules.mail.MailModule"/> > > Nick > > > On 8/6/21 1:13 AM, Michael Westbay wrote: >> Hi All, >> >> I'm currently working on moving one of my servers to eXist 5.3.0. >> When I went to 4.x a while back, the "http://exist-db.org/xquery/mail >> <http://exist-db.org/xquery/mail>" module was still included, but it >> appears to be missing in 5.3.0. >> >> Am I missing it somewhere? Did I install it separately? >> >> -- >> Michael Westbay >> Writer/System Administrator >> http://www.japanesebaseball.com/ <http://www.japanesebaseball.com/> |
From: Nick S. <nsi...@nu...> - 2021-08-06 07:06:02
|
This is quite a coincidence. I was just about to ask this same question. I am also upgrading to the new eXist-db v5.3.0 as well and I am getting the error "Could not initialize class.org.exist.xquery.modules.mail.MailModule". I checked conf.xml and it is enabled. <module uri="http://exist-db.org/xquery/mail" class="org.exist.xquery.modules.mail.MailModule"/> Nick On 8/6/21 1:13 AM, Michael Westbay wrote: > Hi All, > > I'm currently working on moving one of my servers to eXist 5.3.0. When > I went to 4.x a while back, the "http://exist-db.org/xquery/mail > <http://exist-db.org/xquery/mail>" module was still included, but it > appears to be missing in 5.3.0. > > Am I missing it somewhere? Did I install it separately? > > -- > Michael Westbay > Writer/System Administrator > http://www.japanesebaseball.com/ <http://www.japanesebaseball.com/> > > > _______________________________________________ > Exist-open mailing list > Exi...@li... > https://lists.sourceforge.net/lists/listinfo/exist-open -- Nick Sincaglia President/Founder NueMeta, LLC Digital Media & Technology Phone: +1-630-303-7035 nsi...@nu... http://www.nuemeta.com Skype: nsincaglia |
From: Michael W. <wes...@ja...> - 2021-08-06 06:14:01
|
Hi All, I'm currently working on moving one of my servers to eXist 5.3.0. When I went to 4.x a while back, the "http://exist-db.org/xquery/mail" module was still included, but it appears to be missing in 5.3.0. Am I missing it somewhere? Did I install it separately? -- Michael Westbay Writer/System Administrator http://www.japanesebaseball.com/ |
From: Jean-Paul R. <re...@gm...> - 2021-08-03 19:22:36
|
I use the following Xquery declarations to control output without any issue (....which I took directly from eXist's view.xql): declare namespace output = "http://www.w3.org/2010/xslt-xquery-serialization "; declare option output:method "html5"; declare option output:media-type "text/html"; And some of my outputs are generated in XSLT within Xquery like yours.... JPR On Tue, Aug 3, 2021 at 7:41 PM Christian Achter < chr...@ge...> wrote: > Dear community, > > I have a problem with an XQuery script that calls an XSLT script to > convert some XML from the eXist database to HTML. > > E.g. this XML > > <lb/> > > gets converted to this HTML > > <span class="br" data-lineNum="6"/> > > which is a self-closing <span /> tag. But <span> is not allowed to be a > self-closing tag <span ... /> in HTML. Instead it should be <span > ...></span> with no content, but the attributes as above. > > I tried several things. The XSLT is called from within an XQuery script, > so I declared in this XQuery file: > > declare option exist:serialize "method=xhtml > media-type=application/xhtml+html"; > > But still I get self-closing <span />-tags. > > How can I force the HTML part to be like this: > > <span class="br" data-lineNum="6"></span> > > ?? > > Thanks in advance and let me know if more information is needed. > > Kind regards > Christian > > > > > _______________________________________________ > Exist-open mailing list > Exi...@li... > https://lists.sourceforge.net/lists/listinfo/exist-open > |
From: Craig B. <cra...@ma...> - 2021-08-03 19:08:21
|
I had a similar problem. It boiled down to fn:serialize defaulting to XHTML output, where the self-closing tags are legal, but the browser was interpreting the content as HTML5 rather than XHTML. In HTML5 self-closing tags are illegal on non-void elements, and the browser handles the error by turning all following siblings into children, i.e., the self-closing tag is interpreted as an opening tag with an implicit closing tag at the end of the parent. Made quite a mess of my web page until I finally figured out what was happening. I solved the problem by forcing it to serialize as HTML5, adding something like the following as the options parameter to fn:serialize: <output:serialization-parameters xmlns:output="http://www.w3.org/2010/xslt-xquery-serialization"> <output:method>html</output:method> <output:version>5.0</output:version> </output:serialization-parameters> In your case you might be able to do the equivalent in the serialization option at the top of your script. You might also be able to convince the browser that what it's getting is XHTML. It would need to see a header something like this: Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8 However, it seems that the media-type part of your serialization option should already be doing that, so I'm not sure why your browser isn't handling the XHTML. You could fire up the debugging tools in your browser and see what content type you're really getting in the page headers. I was not able to get the browser to recognize the XHTML content type in my case because it was a portion of the page getting rewritten via AJAX and the content type was application/json. Serializing to HTML5 before embedding the AJAX results in JSON solved the problem for me. > On Aug 3, 2021, at 12:24 PM, Christian Achter <chr...@ge...> wrote: > > Dear community, > > I have a problem with an XQuery script that calls an XSLT script to convert some XML from the eXist database to HTML. > > E.g. this XML > > <lb/> > > gets converted to this HTML > > <span class="br" data-lineNum="6"/> > > which is a self-closing <span /> tag. But <span> is not allowed to be a self-closing tag <span ... /> in HTML. Instead it should be <span ...></span> with no content, but the attributes as above. > > I tried several things. The XSLT is called from within an XQuery script, so I declared in this XQuery file: > > declare option exist:serialize "method=xhtml media-type=application/xhtml+html"; > > But still I get self-closing <span />-tags. > > How can I force the HTML part to be like this: > > <span class="br" data-lineNum="6"></span> > > ?? > > Thanks in advance and let me know if more information is needed. > > Kind regards > Christian > > > > > _______________________________________________ > Exist-open mailing list > Exi...@li... > https://lists.sourceforge.net/lists/listinfo/exist-open ________________________________________ Craig A. Berry "... getting out of a sonnet is much more difficult than getting in." Brad Leithauser |
From: Christian A. <chr...@ge...> - 2021-08-03 17:40:22
|
Dear community, I have a problem with an XQuery script that calls an XSLT script to convert some XML from the eXist database to HTML. E.g. this XML <lb/> gets converted to this HTML <span class="br" data-lineNum="6"/> which is a self-closing <span /> tag. But <span> is not allowed to be a self-closing tag <span ... /> in HTML. Instead it should be <span ...></span> with no content, but the attributes as above. I tried several things. The XSLT is called from within an XQuery script, so I declared in this XQuery file: declare option exist:serialize "method=xhtml media-type=application/xhtml+html"; But still I get self-closing <span />-tags. How can I force the HTML part to be like this: <span class="br" data-lineNum="6"></span> ?? Thanks in advance and let me know if more information is needed. Kind regards Christian |
From: Joe W. <jo...@gm...> - 2021-08-01 17:17:21
|
Greetings, In light of reports of some unexpected problems that users encountered when upgrading to eXist 5.3.0, we have added an advisory to the 5.3.0 release notes: https://exist-db.org/exist/apps/wiki/blogs/eXist/eXistdb530. For your convenience, the content of the advisory is reproduced below. Some of the items had been in the original announcement, but we moved them all up to the top of the release notes to make them more prominent. We hope this helps folks better prepare for this very worthwhile upgrade and makes the upgrade process smoother. Joe - Before upgrading an eXist 5.2.0 or earlier system to eXist 5.3.0 (or as soon as possible after upgrading), be sure to upgrade *existdb-packageservice* to the latest release, version 2.8.13 or higher. Since Dashboard relies on this library for all package-related operations, this upgrade must be performed outside Dashboard. To upgrade this package outside of Dashboard, either submit the following query to eXist via eXide or the Java Admin Client as an admin user: xquery version "3.1"; > repo:remove("http://exist-db.org/apps/existdb-packageservice"), > repo:install-and-deploy("http://exist-db.org/apps/existdb-packageservice", > "http > ://exist-db.org/exist/apps/public-repo/find") - The *shared resources* and *markdown* packages are no longer bundled with eXist-db. If your application depends on those you can still declare dependencies on them in your package metadata and download them from the package repository <https://exist-db.org/exist/apps/public-repo/index.html>. - *eXide*’s app generator function has been removed from eXide v3.0.0, as part of important improvements to the application. For generating apps, please use the much better yeoman-based generator-exist <https://github.com/eXist-db/generator-exist> tool. - *Dashboard* v2.0.8 has a known issue <https://github.com/eXist-db/dashboard/issues/194> that can cause requests a 404 error to appear after logging in to the administrative section. Until a permanent fix has been discovered, you can clear the affected browser of this problem by logging out and back in via eXide or Monex. The default eXist-db configuration settings are not production ready. Make sure to consult our article on best practices before making your eXist-db instance publicly available. The new existdb-config project implements these "best practices" and can easily be used to harden your eXist-db(s) from version 5.1.1 till 5.3.0. - The default eXist-db configuration settings are not production ready. Make sure to consult our article on best practices <https://exist-db.org/exist/apps/doc/production_good_practice.xml> before making your eXist-db instance publicly available. The new existdb-config <https://github.com/eXistSolutions/existdb-config> project implements these "best practices" and can easily be used to harden your eXist-db(s) from version 5.1.1 till 5.3.0. |
From: Eduard D. <ed...@fr...> - 2021-07-30 12:39:56
|
Dear all, Is there a way to make this use an index: [../@type='translation'] Or this: [parent::tei:cit/@type='translation'] I already have a range index defined: <create qname="@type" type="xs:string"/> But it isn't used. Bye, Eduard -- Eduard Drenth, Software Architekt ed...@fr... Doelestrjitte 8 8911 DX Ljouwert +31 58 234 30 47 +31 62 094 34 28 (privé) skype: eduarddrenth https://github.com/eduarddrenth frisian.eu gpg: https://pgp.surfnet.nl/pks/lookup?search=eduarddrenth Op freed bin ik thús/wurkje ik minder |
From: Eduard D. <ed...@fr...> - 2021-07-30 11:13:05
|
Dear all, In exist 5.3.0 I have a range index defined: <create qname="tei:cit"> <field name="cit-type" match="@type" type="xs:string"/> </create> I see it back in monex, but... it is empty! What can be the problem? Regards, Eduard -- Eduard Drenth, Software Architekt ed...@fr... Doelestrjitte 8 8911 DX Ljouwert +31 58 234 30 47 +31 62 094 34 28 (privé) skype: eduarddrenth https://github.com/eduarddrenth frisian.eu gpg: https://pgp.surfnet.nl/pks/lookup?search=eduarddrenth Op freed bin ik thús/wurkje ik minder |
From: Ian D. <ia...@xc...> - 2021-07-28 17:38:54
|
Hello, We were trying to migrate an eXist database to a new machine by backing up the relevant collections from the old one (using the Java admin client) and restoring them into the new one. This has always run seamlessly when both the source and target databases have the same admin password, but when trying to restore into a database with a different admin password, it appeared to succeed, but now for some reason we are unable to log in as admin anymore. Neither the source nor target password work. We are running 5.3.0 on the target and 4.7.1 on the source. Thanks, -- Ian Davey Senior Engineer Xcential Corporation |
From: <kev...@xp...> - 2021-07-27 18:51:15
|
Christian: It is a closed system done for a customer. However I have no issues in sharing parts of this. I will send you email offline and if I get a chance this week carve out something on GIT or send it direct to you. Kevin From: Christian Wittern <cwi...@gm...> Sent: Monday, July 26, 2021 7:12 PM To: exi...@li... Subject: Re: [Exist-open] merging XML Hi Kevin, This sounds interesting. Is you code available somewhere? I'd like to study it, especially the XQuery part. All the best, Christian On 27/07/2021 04.19, kev...@xp... <mailto:kev...@xp...> wrote: We have a similar system for patient consent documents and several other hospital-related documents. We started with a combination for the authors, some customized Summernote (like CKEditor) and also Microsoft Word. The Word environment proved the best because we developed 2-way support for exist-db. Outbound we build a custom “document.xml”, using XSLT converting from their XML to Microsoft’s WORDML, stick it into a folder that has all the other .DOCX components, zip it up and send to download as a DOCX. All of this is in XQuery so they simply check out a document (or create a new default one) and after a second or two, a DOCX is downloaded to them. Author’s could work on what they wished and when finished upload the DOCX as a checkin. We use XQuery then to unzip, extract the “document.xml” and then basically reverse it through XSLT to make their XML and update the database. This method also worked great with their language translation vendors who run the DOCX through translation memory and upload the new French/Arabic/Welsh/Chinese/15+ other languages. Word Styles are used to understand structures (headings, lists, captions) but also impart logic. They have “chunks” of information that are finally rendered on demand to PDF through RenderX from exist-db (live at the hospital when needed) and the output content is customized with Choose/When or If structures that use Word styles to convey that. Like “If the logged in hospital is in the UK, show this paragraph, but if in Australia show this one …” Anyway, we found Word to be the best authoring environment for the authors primarily because XSLT can be used to strip out things not needed and while it is complex, it is all there. Even with HTML editors like CKEditor or Summernote, authors would write in Word and then copy/paste into the editor and the results (while they look ok, are rife with custom Word namespaces and HTML entities) that you have to program around and/or strip Javascript side before upload. With Word, we even extract the images (all SVG) and embed them into the Word document so they can see them and write content referencing it since modern Word supports SVG in Word documents now. Kevin From: Alfredo Cosco <mailto:alf...@gm...> <alf...@gm...> Sent: Monday, July 26, 2021 7:31 AM To: Joe Wicentowski <mailto:jo...@gm...> <jo...@gm...> Cc: exist-open <mailto:exi...@li...> <exi...@li...> Subject: Re: [Exist-open] merging XML Hi Joe, yes I did, a couple of years ago, but I discarded the use of XForms because for the textareas they used an editor (it seems to me CKeditor) and to change it was necessary to completely recompile the application (and I have no idea how to do it) . Since I needed an XML editor I developed my own CODEMIRROR configuration dedicated to TEI-XML which guides my editors to write XML easily and, on the side, also has a "note taking environment" https://orazionelson.github.io/CodeMirrorXML4TEI/ https://orazionelson.github.io/CodeMirrorXML4TEI/editor.html Thanks for the suggestions, I will try to study the links you gave me. Alfredo Il giorno lun 26 lug 2021 alle ore 15:28 Joe Wicentowski < <mailto:jo...@gm...> jo...@gm...> ha scritto: Hi Alfredo, It sounds like you're trying to take the input of HTML forms and generate XML documents from the input. Have you investigated XForms, which can natively store XML models in the browser and submit XML instances to eXist? For XForms implementations, see XSLTForms [1] and Fore ("XFormish") [2]. To learn more about XForms, see Steven Pemberton's tutorial [3]. [1] https://github.com/AlainCouthures/declarative4all/raw/master/public/direct/xsltforms.zip [2] https://github.com/Jinntec/Fore [3] https://homepages.cwi.nl/~steven/xforms/xforms-hands-on/ Joe On Sun, Jul 25, 2021 at 1:46 PM Alfredo Cosco <alf...@gm... <mailto:alf...@gm...> > wrote: Hello Joe, Hi all, thanks for the code on github, I'm going to use it as a starting point but reading your message I realized that in few I'll have other problems to face. For example, if an element admits more than one attribute I'll have two identical code snapshots to merge with different attributes. I'll try to write rules from different cases, but after this thread I'm also thinking of rewriting all the logic of my script. What I'm trying to do is to create a TEI document starting from a web-form, the form may vary depending from the user configurations So: 1) I set the attribute "name" in the html input in this way: fileDesc_titleStmt_title or fileDesc_sourceDesc_msDesc_physDesc_objectDesc or (for attributes) fileDesc_sourceDesc_msDesc_physDesc_objectDesc_@form 2) Thanks to this forum I found a way (few weeks ago) to transform the name value in an XML snapshot: <fileDesc> <titleStmt> <title/> </titleStmt> </fileDesc> 3) Then I merge the snapshots and store an empty document in the database 4) Then I add the element and attribute values using the "UPDATE INSERT" In theory the approach works, but in practice seems to bring more troubles than solutions :\ What do you think? Alfredo Il giorno dom 25 lug 2021 alle ore 17:54 Joe Wicentowski <jo...@gm... <mailto:jo...@gm...> > ha scritto: Hi Alfredo, Slav asks good questions about the assumptions in your sample code. Assuming that duplicates should be merged rather than preserved, and testing only for element names (i.e., not examining attribute or text nodes), here's a basic query that will merge your fragments together into a structure approximating your target: https://gist.github.com/joewiz/b38279b8bd33de6949bb891370f76a04 Note that the order of fragments in the sequence you pass to the merge-fragments function is important. This is because when a new fragment is tested against the running composite document, if an element in the fragment doesn't match the element in the composite document, the fragment's element is deposited first before the rest of the composite document. This is why var3's titleStmt element appears first in the composite document, and var2's msIdentifier appears before var1's physDesc. Hopefully this gets you off to a good start and you're able to add any necessary checks besides element name to this to meet any other unstated assumptions / requirements. Joe On Sun, Jul 25, 2021 at 7:32 AM Слава Седов <wet...@gm... <mailto:wet...@gm...> > wrote: Hi, If your input and output set as testcase - it is 100% testcase or data may vary? Do you need removing any duplicates if any or it is not possible in your input? With best wishes, Slav вс, 25 июл. 2021 г., 14:56 Alfredo Cosco <alf...@gm... <mailto:alf...@gm...> >: Hi Jean-Paul, I'm trying to merge the pieces on an "in memory" document then to store the result in a new document. But this logic can change if there is a better way. Thanks, Alfredo Il giorno sab 24 lug 2021 alle ore 19:16 Jean-Paul Rehr <re...@gm... <mailto:re...@gm...> > ha scritto: Alfredo, are you creating a TEI document in memory, or are you trying to insert these into an existing document stored in eXist-db? JPR On Sat, Jul 24, 2021 at 7:04 PM Alfredo Cosco <alf...@gm... <mailto:alf...@gm...> > wrote: Hi all, I'm working on eXist 4.7 The problem is: I have tre variables with XML code: let $var1 := <fileDesc> <sourceDesc> <msDesc> <physDesc> <objectDesc form=""/> </physDesc> </msDesc> </sourceDesc> </fileDesc> let var2 := <fileDesc> <sourceDesc> <msDesc> <msIdentifier> <idno/> </msIdentifier> </msDesc> </sourceDesc> </fileDesc> let var3 := <fileDesc> <titleStmt> <title/> </titleStmt> </fileDesc> How can I merge there 3 snapshots and obtain something like: <fileDesc> <titleStmt> <title/> </titleStmt> <sourceDesc> <msDesc> <physDesc> <objectDesc form=""/> </physDesc> <msIdentifier> <idno/> </msIdentifier> </msDesc> </sourceDesc> </fileDesc> Thanks, Alfredo _______________________________________________ Exist-open mailing list Exi...@li... <mailto:Exi...@li...> https://lists.sourceforge.net/lists/listinfo/exist-open _______________________________________________ Exist-open mailing list Exi...@li... <mailto:Exi...@li...> https://lists.sourceforge.net/lists/listinfo/exist-open _______________________________________________ Exist-open mailing list Exi...@li... <mailto:Exi...@li...> https://lists.sourceforge.net/lists/listinfo/exist-open _______________________________________________ Exist-open mailing list Exi...@li... <mailto:Exi...@li...> https://lists.sourceforge.net/lists/listinfo/exist-open |
From: Christian W. <cwi...@gm...> - 2021-07-27 02:12:22
|
Hi Kevin, This sounds interesting. Is you code available somewhere? I'd like to study it, especially the XQuery part. All the best, Christian On 27/07/2021 04.19, kev...@xp... wrote: > > We have a similar system for patient consent documents and several > other hospital-related documents. > > We started with a combination for the authors, some customized > Summernote (like CKEditor) and also Microsoft Word. > > The Word environment proved the best because we developed 2-way > support for exist-db. > > Outbound we build a custom “document.xml”, using XSLT converting from > their XML to Microsoft’s WORDML, stick it into a folder that has all > the other .DOCX components, zip it up and send to download as a DOCX. > All of this is in XQuery so they simply check out a document (or > create a new default one) and after a second or two, a DOCX is > downloaded to them. > > Author’s could work on what they wished and when finished upload the > DOCX as a checkin. > > We use XQuery then to unzip, extract the “document.xml” and then > basically reverse it through XSLT to make their XML and update the > database. > > This method also worked great with their language translation vendors > who run the DOCX through translation memory and upload the new > French/Arabic/Welsh/Chinese/15+ other languages. > > Word Styles are used to understand structures (headings, lists, > captions) but also impart logic. They have “chunks” of information > that are finally rendered on demand to PDF through RenderX from > exist-db (live at the hospital when needed) and the output content is > customized with Choose/When or If structures that use Word styles to > convey that. Like “If the logged in hospital is in the UK, show this > paragraph, but if in Australia show this one …” > > Anyway, we found Word to be the best authoring environment for the > authors primarily because XSLT can be used to strip out things not > needed and while it is complex, it is all there. Even with HTML > editors like CKEditor or Summernote, authors would write in Word and > then copy/paste into the editor and the results (while they look ok, > are rife with custom Word namespaces and HTML entities) that you have > to program around and/or strip Javascript side before upload. With > Word, we even extract the images (all SVG) and embed them into the > Word document so they can see them and write content referencing it > since modern Word supports SVG in Word documents now. > > Kevin > > *From:* Alfredo Cosco <alf...@gm...> > *Sent:* Monday, July 26, 2021 7:31 AM > *To:* Joe Wicentowski <jo...@gm...> > *Cc:* exist-open <exi...@li...> > *Subject:* Re: [Exist-open] merging XML > > Hi Joe, > yes I did, a couple of years ago, but I discarded the use of XForms > because for the textareas they used an editor (it seems to me > CKeditor) and to change it was necessary to completely recompile the > application (and I have no idea how to do it) . > Since I needed an XML editor I developed my own CODEMIRROR > configuration dedicated to TEI-XML which guides my editors to write > XML easily and, on the side, also has a "note taking environment" > > https://orazionelson.github.io/CodeMirrorXML4TEI/ > <https://orazionelson.github.io/CodeMirrorXML4TEI/> > https://orazionelson.github.io/CodeMirrorXML4TEI/editor.html > <https://orazionelson.github.io/CodeMirrorXML4TEI/editor.html> > > Thanks for the suggestions, I will try to study the links you gave me. > > Alfredo > > Il giorno lun 26 lug 2021 alle ore 15:28 Joe Wicentowski > <jo...@gm... <mailto:jo...@gm...>> ha scritto: > > Hi Alfredo, > > It sounds like you're trying to take the input of HTML forms and > generate XML documents from the input. Have you investigated > XForms, which can natively store XML models in the browser and > submit XML instances to eXist? For XForms implementations, see > XSLTForms [1] and Fore ("XFormish") [2]. To learn more about > XForms, see Steven Pemberton's tutorial [3]. > > [1] > https://github.com/AlainCouthures/declarative4all/raw/master/public/direct/xsltforms.zip > <https://github.com/AlainCouthures/declarative4all/raw/master/public/direct/xsltforms.zip> > > [2] https://github.com/Jinntec/Fore <https://github.com/Jinntec/Fore> > > [3] https://homepages.cwi.nl/~steven/xforms/xforms-hands-on/ > <https://homepages.cwi.nl/~steven/xforms/xforms-hands-on/> > > Joe > > On Sun, Jul 25, 2021 at 1:46 PM Alfredo Cosco > <alf...@gm... <mailto:alf...@gm...>> wrote: > > Hello Joe, Hi all, > > thanks for the code on github, I'm going to use it as a > starting point but reading your message I realized that in few > I'll have other problems to face. > > For example, if an element admits more than one attribute I'll > have two identical code snapshots to merge with different > attributes. > > I'll try to write rules from different cases, but after this > thread I'm also thinking of rewriting all the logic of my script. > > What I'm trying to do is to create a TEI document starting > from a web-form, the form may vary depending from the user > configurations > > So: > > 1) I set the attribute "name" in the html input in this way: > *fileDesc_titleStmt_title* or > *fileDesc_sourceDesc_msDesc_physDesc_objectDesc *or (for > attributes) > > *fileDesc_sourceDesc_msDesc_physDesc_objectDesc_@form* > > 2) Thanks to this forum I found a way (few weeks ago) to > transform the *name* value in an XML snapshot: > > <fileDesc> > <titleStmt> > <title/> > </titleStmt> > </fileDesc> > > 3) Then I merge the snapshots and store an empty document in > the database > > 4) Then I add the element and attribute values using the > "UPDATE INSERT" > > In theory the approach works, but in practice seems to bring > more troubles than solutions :\ > > What do you think? > > Alfredo > > Il giorno dom 25 lug 2021 alle ore 17:54 Joe Wicentowski > <jo...@gm... <mailto:jo...@gm...>> ha scritto: > > Hi Alfredo, > > Slav asks good questions about the assumptions in your > sample code. Assuming that duplicates should be merged > rather than preserved, and testing only for element names > (i.e., not examining attribute or text nodes), here's a > basic query that will merge your fragments together into a > structure approximating your target: > > https://gist.github.com/joewiz/b38279b8bd33de6949bb891370f76a04 > <https://gist.github.com/joewiz/b38279b8bd33de6949bb891370f76a04> > > Note that the order of fragments in the sequence you pass > to the merge-fragments function is important. This is > because when a new fragment is tested against the running > composite document, if an element in the fragment doesn't > match the element in the composite document, the > fragment's element is deposited first before the rest of > the composite document. This is why var3's titleStmt > element appears first in the composite document, and > var2's msIdentifier appears before var1's physDesc. > > Hopefully this gets you off to a good start and you're > able to add any necessary checks besides element name to > this to meet any other unstated assumptions / requirements. > > Joe > > On Sun, Jul 25, 2021 at 7:32 AM Слава Седов > <wet...@gm... <mailto:wet...@gm...>> wrote: > > Hi, > > If your input and output set as testcase - it is 100% > testcase or data may vary? Do you need removing any > duplicates if any or it is not possible in your input? > > With best wishes, > > Slav > > вс, 25 июл. 2021 г., 14:56 Alfredo Cosco > <alf...@gm... > <mailto:alf...@gm...>>: > > Hi Jean-Paul, > > I'm trying to merge the pieces on an "in > memory" document then to store the result in a new > document. > > But this logic can change if there is a better way. > > Thanks, > > Alfredo > > Il giorno sab 24 lug 2021 alle ore 19:16 Jean-Paul > Rehr <re...@gm... <mailto:re...@gm...>> > ha scritto: > > Alfredo, are you creating a TEI document in > memory, or are you trying to insert these into > an existing document stored in eXist-db? > > JPR > > On Sat, Jul 24, 2021 at 7:04 PM Alfredo Cosco > <alf...@gm... > <mailto:alf...@gm...>> wrote: > > Hi all, > > I'm working on eXist 4.7 > > The problem is: > > I have tre variables with XML code: > > let $var1 := <fileDesc> > > <sourceDesc> > > <msDesc> > > <physDesc> > > <objectDesc form=""/> > > </physDesc> > > </msDesc> > > </sourceDesc> > > </fileDesc> > > let var2 := <fileDesc> > > <sourceDesc> > > <msDesc> > > <msIdentifier> > > <idno/> > > </msIdentifier> > > </msDesc> > > </sourceDesc> > > </fileDesc> > > let var3 := <fileDesc> > > <titleStmt> > > <title/> > > </titleStmt> > > </fileDesc> > > How can I merge there 3 snapshots and > obtain something like: > > <fileDesc> > > <titleStmt> > > <title/> > > </titleStmt> > > <sourceDesc> > > <msDesc> > > <physDesc> > > <objectDesc form=""/> > > </physDesc> > > <msIdentifier> > > <idno/> > > </msIdentifier> > > </msDesc> > > </sourceDesc> > > </fileDesc> > > Thanks, > > Alfredo > > _______________________________________________ > Exist-open mailing list > Exi...@li... > <mailto:Exi...@li...> > https://lists.sourceforge.net/lists/listinfo/exist-open > <https://lists.sourceforge.net/lists/listinfo/exist-open> > > _______________________________________________ > Exist-open mailing list > Exi...@li... > <mailto:Exi...@li...> > https://lists.sourceforge.net/lists/listinfo/exist-open > <https://lists.sourceforge.net/lists/listinfo/exist-open> > > _______________________________________________ > Exist-open mailing list > Exi...@li... > <mailto:Exi...@li...> > https://lists.sourceforge.net/lists/listinfo/exist-open > <https://lists.sourceforge.net/lists/listinfo/exist-open> > > > > _______________________________________________ > Exist-open mailing list > Exi...@li... > https://lists.sourceforge.net/lists/listinfo/exist-open |
From: <kev...@xp...> - 2021-07-26 19:20:14
|
We have a similar system for patient consent documents and several other hospital-related documents. We started with a combination for the authors, some customized Summernote (like CKEditor) and also Microsoft Word. The Word environment proved the best because we developed 2-way support for exist-db. Outbound we build a custom “document.xml”, using XSLT converting from their XML to Microsoft’s WORDML, stick it into a folder that has all the other .DOCX components, zip it up and send to download as a DOCX. All of this is in XQuery so they simply check out a document (or create a new default one) and after a second or two, a DOCX is downloaded to them. Author’s could work on what they wished and when finished upload the DOCX as a checkin. We use XQuery then to unzip, extract the “document.xml” and then basically reverse it through XSLT to make their XML and update the database. This method also worked great with their language translation vendors who run the DOCX through translation memory and upload the new French/Arabic/Welsh/Chinese/15+ other languages. Word Styles are used to understand structures (headings, lists, captions) but also impart logic. They have “chunks” of information that are finally rendered on demand to PDF through RenderX from exist-db (live at the hospital when needed) and the output content is customized with Choose/When or If structures that use Word styles to convey that. Like “If the logged in hospital is in the UK, show this paragraph, but if in Australia show this one …” Anyway, we found Word to be the best authoring environment for the authors primarily because XSLT can be used to strip out things not needed and while it is complex, it is all there. Even with HTML editors like CKEditor or Summernote, authors would write in Word and then copy/paste into the editor and the results (while they look ok, are rife with custom Word namespaces and HTML entities) that you have to program around and/or strip Javascript side before upload. With Word, we even extract the images (all SVG) and embed them into the Word document so they can see them and write content referencing it since modern Word supports SVG in Word documents now. Kevin From: Alfredo Cosco <alf...@gm...> Sent: Monday, July 26, 2021 7:31 AM To: Joe Wicentowski <jo...@gm...> Cc: exist-open <exi...@li...> Subject: Re: [Exist-open] merging XML Hi Joe, yes I did, a couple of years ago, but I discarded the use of XForms because for the textareas they used an editor (it seems to me CKeditor) and to change it was necessary to completely recompile the application (and I have no idea how to do it) . Since I needed an XML editor I developed my own CODEMIRROR configuration dedicated to TEI-XML which guides my editors to write XML easily and, on the side, also has a "note taking environment" https://orazionelson.github.io/CodeMirrorXML4TEI/ https://orazionelson.github.io/CodeMirrorXML4TEI/editor.html Thanks for the suggestions, I will try to study the links you gave me. Alfredo Il giorno lun 26 lug 2021 alle ore 15:28 Joe Wicentowski <jo...@gm... <mailto:jo...@gm...> > ha scritto: Hi Alfredo, It sounds like you're trying to take the input of HTML forms and generate XML documents from the input. Have you investigated XForms, which can natively store XML models in the browser and submit XML instances to eXist? For XForms implementations, see XSLTForms [1] and Fore ("XFormish") [2]. To learn more about XForms, see Steven Pemberton's tutorial [3]. [1] https://github.com/AlainCouthures/declarative4all/raw/master/public/direct/xsltforms.zip [2] https://github.com/Jinntec/Fore [3] https://homepages.cwi.nl/~steven/xforms/xforms-hands-on/ Joe On Sun, Jul 25, 2021 at 1:46 PM Alfredo Cosco <alf...@gm... <mailto:alf...@gm...> > wrote: Hello Joe, Hi all, thanks for the code on github, I'm going to use it as a starting point but reading your message I realized that in few I'll have other problems to face. For example, if an element admits more than one attribute I'll have two identical code snapshots to merge with different attributes. I'll try to write rules from different cases, but after this thread I'm also thinking of rewriting all the logic of my script. What I'm trying to do is to create a TEI document starting from a web-form, the form may vary depending from the user configurations So: 1) I set the attribute "name" in the html input in this way: fileDesc_titleStmt_title or fileDesc_sourceDesc_msDesc_physDesc_objectDesc or (for attributes) fileDesc_sourceDesc_msDesc_physDesc_objectDesc_@form 2) Thanks to this forum I found a way (few weeks ago) to transform the name value in an XML snapshot: <fileDesc> <titleStmt> <title/> </titleStmt> </fileDesc> 3) Then I merge the snapshots and store an empty document in the database 4) Then I add the element and attribute values using the "UPDATE INSERT" In theory the approach works, but in practice seems to bring more troubles than solutions :\ What do you think? Alfredo Il giorno dom 25 lug 2021 alle ore 17:54 Joe Wicentowski <jo...@gm... <mailto:jo...@gm...> > ha scritto: Hi Alfredo, Slav asks good questions about the assumptions in your sample code. Assuming that duplicates should be merged rather than preserved, and testing only for element names (i.e., not examining attribute or text nodes), here's a basic query that will merge your fragments together into a structure approximating your target: https://gist.github.com/joewiz/b38279b8bd33de6949bb891370f76a04 Note that the order of fragments in the sequence you pass to the merge-fragments function is important. This is because when a new fragment is tested against the running composite document, if an element in the fragment doesn't match the element in the composite document, the fragment's element is deposited first before the rest of the composite document. This is why var3's titleStmt element appears first in the composite document, and var2's msIdentifier appears before var1's physDesc. Hopefully this gets you off to a good start and you're able to add any necessary checks besides element name to this to meet any other unstated assumptions / requirements. Joe On Sun, Jul 25, 2021 at 7:32 AM Слава Седов <wet...@gm... <mailto:wet...@gm...> > wrote: Hi, If your input and output set as testcase - it is 100% testcase or data may vary? Do you need removing any duplicates if any or it is not possible in your input? With best wishes, Slav вс, 25 июл. 2021 г., 14:56 Alfredo Cosco <alf...@gm... <mailto:alf...@gm...> >: Hi Jean-Paul, I'm trying to merge the pieces on an "in memory" document then to store the result in a new document. But this logic can change if there is a better way. Thanks, Alfredo Il giorno sab 24 lug 2021 alle ore 19:16 Jean-Paul Rehr <re...@gm... <mailto:re...@gm...> > ha scritto: Alfredo, are you creating a TEI document in memory, or are you trying to insert these into an existing document stored in eXist-db? JPR On Sat, Jul 24, 2021 at 7:04 PM Alfredo Cosco <alf...@gm... <mailto:alf...@gm...> > wrote: Hi all, I'm working on eXist 4.7 The problem is: I have tre variables with XML code: let $var1 := <fileDesc> <sourceDesc> <msDesc> <physDesc> <objectDesc form=""/> </physDesc> </msDesc> </sourceDesc> </fileDesc> let var2 := <fileDesc> <sourceDesc> <msDesc> <msIdentifier> <idno/> </msIdentifier> </msDesc> </sourceDesc> </fileDesc> let var3 := <fileDesc> <titleStmt> <title/> </titleStmt> </fileDesc> How can I merge there 3 snapshots and obtain something like: <fileDesc> <titleStmt> <title/> </titleStmt> <sourceDesc> <msDesc> <physDesc> <objectDesc form=""/> </physDesc> <msIdentifier> <idno/> </msIdentifier> </msDesc> </sourceDesc> </fileDesc> Thanks, Alfredo _______________________________________________ Exist-open mailing list Exi...@li... <mailto:Exi...@li...> https://lists.sourceforge.net/lists/listinfo/exist-open _______________________________________________ Exist-open mailing list Exi...@li... <mailto:Exi...@li...> https://lists.sourceforge.net/lists/listinfo/exist-open _______________________________________________ Exist-open mailing list Exi...@li... <mailto:Exi...@li...> https://lists.sourceforge.net/lists/listinfo/exist-open |
From: Alfredo C. <alf...@gm...> - 2021-07-26 14:31:56
|
Hi Joe, yes I did, a couple of years ago, but I discarded the use of XForms because for the textareas they used an editor (it seems to me CKeditor) and to change it was necessary to completely recompile the application (and I have no idea how to do it) . Since I needed an XML editor I developed my own CODEMIRROR configuration dedicated to TEI-XML which guides my editors to write XML easily and, on the side, also has a "note taking environment" https://orazionelson.github.io/CodeMirrorXML4TEI/ https://orazionelson.github.io/CodeMirrorXML4TEI/editor.html Thanks for the suggestions, I will try to study the links you gave me. Alfredo Il giorno lun 26 lug 2021 alle ore 15:28 Joe Wicentowski <jo...@gm...> ha scritto: > Hi Alfredo, > > It sounds like you're trying to take the input of HTML forms and generate > XML documents from the input. Have you investigated XForms, which can > natively store XML models in the browser and submit XML instances to eXist? > For XForms implementations, see XSLTForms [1] and Fore ("XFormish") [2]. To > learn more about XForms, see Steven Pemberton's tutorial [3]. > > [1] > https://github.com/AlainCouthures/declarative4all/raw/master/public/direct/xsltforms.zip > [2] https://github.com/Jinntec/Fore > [3] https://homepages.cwi.nl/~steven/xforms/xforms-hands-on/ > > Joe > > > On Sun, Jul 25, 2021 at 1:46 PM Alfredo Cosco <alf...@gm...> > wrote: > >> Hello Joe, Hi all, >> thanks for the code on github, I'm going to use it as a starting point >> but reading your message I realized that in few I'll have other problems to >> face. >> >> For example, if an element admits more than one attribute I'll have two >> identical code snapshots to merge with different attributes. >> >> I'll try to write rules from different cases, but after this thread I'm >> also thinking of rewriting all the logic of my script. >> >> What I'm trying to do is to create a TEI document starting from a >> web-form, the form may vary depending from the user configurations >> >> So: >> 1) I set the attribute "name" in the html input in this way: >> *fileDesc_titleStmt_title* or * >> fileDesc_sourceDesc_msDesc_physDesc_objectDesc *or (for attributes) >> *fileDesc_sourceDesc_msDesc_physDesc_objectDesc_@form* >> >> 2) Thanks to this forum I found a way (few weeks ago) to transform the >> *name* value in an XML snapshot: >> <fileDesc> >> <titleStmt> >> <title/> >> </titleStmt> >> </fileDesc> >> >> 3) Then I merge the snapshots and store an empty document in the database >> >> 4) Then I add the element and attribute values using the "UPDATE INSERT" >> >> In theory the approach works, but in practice seems to bring more >> troubles than solutions :\ >> >> What do you think? >> >> Alfredo >> >> >> >> >> >> >> >> >> Il giorno dom 25 lug 2021 alle ore 17:54 Joe Wicentowski < >> jo...@gm...> ha scritto: >> >>> Hi Alfredo, >>> >>> Slav asks good questions about the assumptions in your sample code. >>> Assuming that duplicates should be merged rather than preserved, and >>> testing only for element names (i.e., not examining attribute or text >>> nodes), here's a basic query that will merge your fragments together into a >>> structure approximating your target: >>> >>> https://gist.github.com/joewiz/b38279b8bd33de6949bb891370f76a04 >>> >>> Note that the order of fragments in the sequence you pass to the >>> merge-fragments function is important. This is because when a new fragment >>> is tested against the running composite document, if an element in the >>> fragment doesn't match the element in the composite document, the >>> fragment's element is deposited first before the rest of the composite >>> document. This is why var3's titleStmt element appears first in the >>> composite document, and var2's msIdentifier appears before var1's physDesc. >>> >>> Hopefully this gets you off to a good start and you're able to add any >>> necessary checks besides element name to this to meet any other unstated >>> assumptions / requirements. >>> >>> Joe >>> >>> On Sun, Jul 25, 2021 at 7:32 AM Слава Седов <wet...@gm...> wrote: >>> >>>> Hi, >>>> >>>> If your input and output set as testcase - it is 100% testcase or data >>>> may vary? Do you need removing any duplicates if any or it is not possible >>>> in your input? >>>> >>>> With best wishes, >>>> Slav >>>> >>>> вс, 25 июл. 2021 г., 14:56 Alfredo Cosco <alf...@gm...>: >>>> >>>>> Hi Jean-Paul, >>>>> I'm trying to merge the pieces on an "in memory" document then to >>>>> store the result in a new document. >>>>> But this logic can change if there is a better way. >>>>> Thanks, >>>>> Alfredo >>>>> >>>>> Il giorno sab 24 lug 2021 alle ore 19:16 Jean-Paul Rehr < >>>>> re...@gm...> ha scritto: >>>>> >>>>>> Alfredo, are you creating a TEI document in memory, or are you trying >>>>>> to insert these into an existing document stored in eXist-db? >>>>>> >>>>>> JPR >>>>>> >>>>>> On Sat, Jul 24, 2021 at 7:04 PM Alfredo Cosco < >>>>>> alf...@gm...> wrote: >>>>>> >>>>>>> Hi all, >>>>>>> I'm working on eXist 4.7 >>>>>>> The problem is: >>>>>>> >>>>>>> I have tre variables with XML code: >>>>>>> >>>>>>> let $var1 := <fileDesc> >>>>>>> <sourceDesc> >>>>>>> <msDesc> >>>>>>> <physDesc> >>>>>>> <objectDesc form=""/> >>>>>>> </physDesc> >>>>>>> </msDesc> >>>>>>> </sourceDesc> >>>>>>> </fileDesc> >>>>>>> >>>>>>> >>>>>>> let var2 := <fileDesc> >>>>>>> <sourceDesc> >>>>>>> <msDesc> >>>>>>> <msIdentifier> >>>>>>> <idno/> >>>>>>> </msIdentifier> >>>>>>> </msDesc> >>>>>>> </sourceDesc> >>>>>>> </fileDesc> >>>>>>> >>>>>>> let var3 := <fileDesc> >>>>>>> <titleStmt> >>>>>>> <title/> >>>>>>> </titleStmt> >>>>>>> </fileDesc> >>>>>>> >>>>>>> How can I merge there 3 snapshots and obtain something like: >>>>>>> >>>>>>> <fileDesc> >>>>>>> <titleStmt> >>>>>>> <title/> >>>>>>> </titleStmt> >>>>>>> <sourceDesc> >>>>>>> <msDesc> >>>>>>> <physDesc> >>>>>>> <objectDesc form=""/> >>>>>>> </physDesc> >>>>>>> <msIdentifier> >>>>>>> <idno/> >>>>>>> </msIdentifier> >>>>>>> </msDesc> >>>>>>> </sourceDesc> >>>>>>> </fileDesc> >>>>>>> >>>>>>> >>>>>>> Thanks, >>>>>>> Alfredo >>>>>>> _______________________________________________ >>>>>>> Exist-open mailing list >>>>>>> Exi...@li... >>>>>>> https://lists.sourceforge.net/lists/listinfo/exist-open >>>>>>> >>>>>> _______________________________________________ >>>>> Exist-open mailing list >>>>> Exi...@li... >>>>> https://lists.sourceforge.net/lists/listinfo/exist-open >>>>> >>>> _______________________________________________ >>>> Exist-open mailing list >>>> Exi...@li... >>>> https://lists.sourceforge.net/lists/listinfo/exist-open >>>> >>> |
From: Joe W. <jo...@gm...> - 2021-07-26 13:28:15
|
Hi Alfredo, It sounds like you're trying to take the input of HTML forms and generate XML documents from the input. Have you investigated XForms, which can natively store XML models in the browser and submit XML instances to eXist? For XForms implementations, see XSLTForms [1] and Fore ("XFormish") [2]. To learn more about XForms, see Steven Pemberton's tutorial [3]. [1] https://github.com/AlainCouthures/declarative4all/raw/master/public/direct/xsltforms.zip [2] https://github.com/Jinntec/Fore [3] https://homepages.cwi.nl/~steven/xforms/xforms-hands-on/ Joe On Sun, Jul 25, 2021 at 1:46 PM Alfredo Cosco <alf...@gm...> wrote: > Hello Joe, Hi all, > thanks for the code on github, I'm going to use it as a starting point but > reading your message I realized that in few I'll have other problems to > face. > > For example, if an element admits more than one attribute I'll have two > identical code snapshots to merge with different attributes. > > I'll try to write rules from different cases, but after this thread I'm > also thinking of rewriting all the logic of my script. > > What I'm trying to do is to create a TEI document starting from a > web-form, the form may vary depending from the user configurations > > So: > 1) I set the attribute "name" in the html input in this way: > *fileDesc_titleStmt_title* or * > fileDesc_sourceDesc_msDesc_physDesc_objectDesc *or (for attributes) > *fileDesc_sourceDesc_msDesc_physDesc_objectDesc_@form* > > 2) Thanks to this forum I found a way (few weeks ago) to transform the > *name* value in an XML snapshot: > <fileDesc> > <titleStmt> > <title/> > </titleStmt> > </fileDesc> > > 3) Then I merge the snapshots and store an empty document in the database > > 4) Then I add the element and attribute values using the "UPDATE INSERT" > > In theory the approach works, but in practice seems to bring more troubles > than solutions :\ > > What do you think? > > Alfredo > > > > > > > > > Il giorno dom 25 lug 2021 alle ore 17:54 Joe Wicentowski <jo...@gm...> > ha scritto: > >> Hi Alfredo, >> >> Slav asks good questions about the assumptions in your sample code. >> Assuming that duplicates should be merged rather than preserved, and >> testing only for element names (i.e., not examining attribute or text >> nodes), here's a basic query that will merge your fragments together into a >> structure approximating your target: >> >> https://gist.github.com/joewiz/b38279b8bd33de6949bb891370f76a04 >> >> Note that the order of fragments in the sequence you pass to the >> merge-fragments function is important. This is because when a new fragment >> is tested against the running composite document, if an element in the >> fragment doesn't match the element in the composite document, the >> fragment's element is deposited first before the rest of the composite >> document. This is why var3's titleStmt element appears first in the >> composite document, and var2's msIdentifier appears before var1's physDesc. >> >> Hopefully this gets you off to a good start and you're able to add any >> necessary checks besides element name to this to meet any other unstated >> assumptions / requirements. >> >> Joe >> >> On Sun, Jul 25, 2021 at 7:32 AM Слава Седов <wet...@gm...> wrote: >> >>> Hi, >>> >>> If your input and output set as testcase - it is 100% testcase or data >>> may vary? Do you need removing any duplicates if any or it is not possible >>> in your input? >>> >>> With best wishes, >>> Slav >>> >>> вс, 25 июл. 2021 г., 14:56 Alfredo Cosco <alf...@gm...>: >>> >>>> Hi Jean-Paul, >>>> I'm trying to merge the pieces on an "in memory" document then to store >>>> the result in a new document. >>>> But this logic can change if there is a better way. >>>> Thanks, >>>> Alfredo >>>> >>>> Il giorno sab 24 lug 2021 alle ore 19:16 Jean-Paul Rehr < >>>> re...@gm...> ha scritto: >>>> >>>>> Alfredo, are you creating a TEI document in memory, or are you trying >>>>> to insert these into an existing document stored in eXist-db? >>>>> >>>>> JPR >>>>> >>>>> On Sat, Jul 24, 2021 at 7:04 PM Alfredo Cosco <alf...@gm...> >>>>> wrote: >>>>> >>>>>> Hi all, >>>>>> I'm working on eXist 4.7 >>>>>> The problem is: >>>>>> >>>>>> I have tre variables with XML code: >>>>>> >>>>>> let $var1 := <fileDesc> >>>>>> <sourceDesc> >>>>>> <msDesc> >>>>>> <physDesc> >>>>>> <objectDesc form=""/> >>>>>> </physDesc> >>>>>> </msDesc> >>>>>> </sourceDesc> >>>>>> </fileDesc> >>>>>> >>>>>> >>>>>> let var2 := <fileDesc> >>>>>> <sourceDesc> >>>>>> <msDesc> >>>>>> <msIdentifier> >>>>>> <idno/> >>>>>> </msIdentifier> >>>>>> </msDesc> >>>>>> </sourceDesc> >>>>>> </fileDesc> >>>>>> >>>>>> let var3 := <fileDesc> >>>>>> <titleStmt> >>>>>> <title/> >>>>>> </titleStmt> >>>>>> </fileDesc> >>>>>> >>>>>> How can I merge there 3 snapshots and obtain something like: >>>>>> >>>>>> <fileDesc> >>>>>> <titleStmt> >>>>>> <title/> >>>>>> </titleStmt> >>>>>> <sourceDesc> >>>>>> <msDesc> >>>>>> <physDesc> >>>>>> <objectDesc form=""/> >>>>>> </physDesc> >>>>>> <msIdentifier> >>>>>> <idno/> >>>>>> </msIdentifier> >>>>>> </msDesc> >>>>>> </sourceDesc> >>>>>> </fileDesc> >>>>>> >>>>>> >>>>>> Thanks, >>>>>> Alfredo >>>>>> _______________________________________________ >>>>>> Exist-open mailing list >>>>>> Exi...@li... >>>>>> https://lists.sourceforge.net/lists/listinfo/exist-open >>>>>> >>>>> _______________________________________________ >>>> Exist-open mailing list >>>> Exi...@li... >>>> https://lists.sourceforge.net/lists/listinfo/exist-open >>>> >>> _______________________________________________ >>> Exist-open mailing list >>> Exi...@li... >>> https://lists.sourceforge.net/lists/listinfo/exist-open >>> >> |
From: Alfredo C. <alf...@gm...> - 2021-07-25 17:46:28
|
Hello Joe, Hi all, thanks for the code on github, I'm going to use it as a starting point but reading your message I realized that in few I'll have other problems to face. For example, if an element admits more than one attribute I'll have two identical code snapshots to merge with different attributes. I'll try to write rules from different cases, but after this thread I'm also thinking of rewriting all the logic of my script. What I'm trying to do is to create a TEI document starting from a web-form, the form may vary depending from the user configurations So: 1) I set the attribute "name" in the html input in this way: *fileDesc_titleStmt_title* or * fileDesc_sourceDesc_msDesc_physDesc_objectDesc *or (for attributes) *fileDesc_sourceDesc_msDesc_physDesc_objectDesc_@form* 2) Thanks to this forum I found a way (few weeks ago) to transform the *name* value in an XML snapshot: <fileDesc> <titleStmt> <title/> </titleStmt> </fileDesc> 3) Then I merge the snapshots and store an empty document in the database 4) Then I add the element and attribute values using the "UPDATE INSERT" In theory the approach works, but in practice seems to bring more troubles than solutions :\ What do you think? Alfredo Il giorno dom 25 lug 2021 alle ore 17:54 Joe Wicentowski <jo...@gm...> ha scritto: > Hi Alfredo, > > Slav asks good questions about the assumptions in your sample code. > Assuming that duplicates should be merged rather than preserved, and > testing only for element names (i.e., not examining attribute or text > nodes), here's a basic query that will merge your fragments together into a > structure approximating your target: > > https://gist.github.com/joewiz/b38279b8bd33de6949bb891370f76a04 > > Note that the order of fragments in the sequence you pass to the > merge-fragments function is important. This is because when a new fragment > is tested against the running composite document, if an element in the > fragment doesn't match the element in the composite document, the > fragment's element is deposited first before the rest of the composite > document. This is why var3's titleStmt element appears first in the > composite document, and var2's msIdentifier appears before var1's physDesc. > > Hopefully this gets you off to a good start and you're able to add any > necessary checks besides element name to this to meet any other unstated > assumptions / requirements. > > Joe > > On Sun, Jul 25, 2021 at 7:32 AM Слава Седов <wet...@gm...> wrote: > >> Hi, >> >> If your input and output set as testcase - it is 100% testcase or data >> may vary? Do you need removing any duplicates if any or it is not possible >> in your input? >> >> With best wishes, >> Slav >> >> вс, 25 июл. 2021 г., 14:56 Alfredo Cosco <alf...@gm...>: >> >>> Hi Jean-Paul, >>> I'm trying to merge the pieces on an "in memory" document then to store >>> the result in a new document. >>> But this logic can change if there is a better way. >>> Thanks, >>> Alfredo >>> >>> Il giorno sab 24 lug 2021 alle ore 19:16 Jean-Paul Rehr < >>> re...@gm...> ha scritto: >>> >>>> Alfredo, are you creating a TEI document in memory, or are you trying >>>> to insert these into an existing document stored in eXist-db? >>>> >>>> JPR >>>> >>>> On Sat, Jul 24, 2021 at 7:04 PM Alfredo Cosco <alf...@gm...> >>>> wrote: >>>> >>>>> Hi all, >>>>> I'm working on eXist 4.7 >>>>> The problem is: >>>>> >>>>> I have tre variables with XML code: >>>>> >>>>> let $var1 := <fileDesc> >>>>> <sourceDesc> >>>>> <msDesc> >>>>> <physDesc> >>>>> <objectDesc form=""/> >>>>> </physDesc> >>>>> </msDesc> >>>>> </sourceDesc> >>>>> </fileDesc> >>>>> >>>>> >>>>> let var2 := <fileDesc> >>>>> <sourceDesc> >>>>> <msDesc> >>>>> <msIdentifier> >>>>> <idno/> >>>>> </msIdentifier> >>>>> </msDesc> >>>>> </sourceDesc> >>>>> </fileDesc> >>>>> >>>>> let var3 := <fileDesc> >>>>> <titleStmt> >>>>> <title/> >>>>> </titleStmt> >>>>> </fileDesc> >>>>> >>>>> How can I merge there 3 snapshots and obtain something like: >>>>> >>>>> <fileDesc> >>>>> <titleStmt> >>>>> <title/> >>>>> </titleStmt> >>>>> <sourceDesc> >>>>> <msDesc> >>>>> <physDesc> >>>>> <objectDesc form=""/> >>>>> </physDesc> >>>>> <msIdentifier> >>>>> <idno/> >>>>> </msIdentifier> >>>>> </msDesc> >>>>> </sourceDesc> >>>>> </fileDesc> >>>>> >>>>> >>>>> Thanks, >>>>> Alfredo >>>>> _______________________________________________ >>>>> Exist-open mailing list >>>>> Exi...@li... >>>>> https://lists.sourceforge.net/lists/listinfo/exist-open >>>>> >>>> _______________________________________________ >>> Exist-open mailing list >>> Exi...@li... >>> https://lists.sourceforge.net/lists/listinfo/exist-open >>> >> _______________________________________________ >> Exist-open mailing list >> Exi...@li... >> https://lists.sourceforge.net/lists/listinfo/exist-open >> > |