Hi, Thanks for your comment. It seems that it's a special case only for "0". The original question can be applied to not only "0" but also other numbers. For example: "2.E+1" and "2E+1"
Let's discuss it as a separated topi. I've opened a new issue for it: https://github.com/apache/arrow/issues/44285 Thanks, -- kou In <CABg-ORvD_VzeEFei=_i2w1yjkymcdbnrpxppbotz1vihuhm...@mail.gmail.com> "Re: [DISCUSS][C++] Can we use "0E+1" not "0.E+1" for deciaml for broader compatibility?" on Tue, 1 Oct 2024 10:50:41 +0200, Jacek Pliszka <jacek.plis...@gmail.com> wrote: > Hi! > > I am a bit puzzled why it is not 0e0. This seems to me the "natural" > way 0 should be written in scientific notation. > > Best Regards, > > Jacek Pliszka > > > >> Le 01/10/2024 à 03:55, Sutou Kouhei a écrit : >> > Hi, >> > >> > The current decimal implementation omits the fractional part >> > if the fractional part is 0. For example: "0.E+1" not "0.0E+1" >> > >> > Most environments such as Python, Node.js, PostgreSQL and >> > MySQL accepts "0.E+1" but some environments such as Ruby >> > don't accept "0.E+1". >> > >> > Can we use "0E+1" (omit "." and "0") or "0.0E+1" (not omit >> > "." and "0") instead of "0.E+1 (omit "0") for broader >> > compatibility? >> > >> > Related issue: https://github.com/apache/arrow/issues/44273 >> > >> > >> > Thanks,