Thank you Christian and Wray
The implicit cast is the problem (as usual). I was expecting it to happen
equally :(
And I teach my students to use value comparisons when ever possible and to care
about the cast yourself ;-)
Yours
Leo
> On 13 Dec 2018, at 10:46, Christian Grün wrote:
>
> Hi
True, the documentation of the command-line flags hasn’t been updated
for quite a while now. I’ve just caught up on that. BaseX 9.1.1 is
scheduled for tomorrow, it will include the updated help texts.
On Thu, Dec 13, 2018 at 2:32 PM Zimmel, Daniel wrote:
>
> Looks like I was not getting the
Looks like I was not getting the toggle part correctly.
Yes it is very confusing since it says:
"-w Preserve whitespaces from input files"
Thanks! I will toggle this now in my internal documentation :-)
> -Ursprüngliche Nachricht-
> Von: Christian Grün
> With the same query, when CHOP=false in the .basex file and -w switch on the
> command line, whitespace gets chopped (not expected!)
The option is toggled (see one of my previous replies). We should
revise the help text on the command-line in a future version.
Thanks for the hint. Yes, in my .basex there is a CHOP=false; when I delete it,
it works as expected.
But as I pointed out, this looks like a bug to me:
With the same query, when CHOP=false in the .basex file and -w switch on the
command line, whitespace gets chopped (not expected!)
Input
This is what I get:
REPLACED
eins
Do you possibly have some settings in your .basex configuration file
that I should consider? Or do you have a 'test' database with chopped
whitespaces that is opened instead of your test.xml document?
On Thu, Dec 13, 2018 at 1:43 PM Zimmel,
I was referring to XQuery update writeback, chop option is set to false:
$ basex.bat -u -w -c"set exporter omit-xml-declaration=no,indent=no" -itest.xml
update.xquery
update.xquery:
for $c in doc(document-uri())//kennung
return
(replace value of node $c with "REPLACED")
test.xml:
test
Ah, now this makes it much more clear in the documentation, I just checked the
wiki page history.
The only thing is I prefer the Saxon default about not changing anything on
already existing indentation (BaseX is deleting any indentation with
indent=no), but I am aware this is
Hi Leo,
The semantics of value comparisons (eq, ne, …) and general comparisons
(=, !=, …) are different. As E. Wray indicated, sequences with more
than one item can be compared with general comparisons; the result
will always be a boolean (value comparisons will return an empty
sequence if at
The value comparison operators (eq, lt, etc.) are designed for comparing single
values (i.e. sequences of one value each). The general comparison operators (=,
<, etc.) are designed for comparing sequences of more than one value.
E. Wray Johnson
> On Dec 13, 2018, at 4:16 AM, Leo Studer
Hello
Could someone explain me why this woks
//country[@population = max(//@population)]/name
Whereas this does not
//country[@population eq max(//@population)]/name
Thanks in advance
Leo
11 matches
Mail list logo