Re: [xsl] How to fuzz the last four digits of a lat/long?

Subject: Re: [xsl] How to fuzz the last four digits of a lat/long?
From: "Michael Kay mike@xxxxxxxxxxxx" <xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx>
Date: Sat, 22 May 2021 13:26:40 -0000
> But, but, but, ....
>
> I really want to do the transformation in one step.

Why?

There are clearly two separate operations here - rounding the value and then
formatting it. I would do

round($x, 2) => format-number("000.000000")

Michael Kay
Saxonica

> Is there a way to do the transformation in one step (using the built-in XSLT
or XPath functions)? As best I can tell, I can't do it in one step using the
format-number() function, right?
>
> Ditto for the longitude transformation.
>
> /Roger

Current Thread