On 2020-03-04 20:35, Mark Rotteveel wrote:
On 04-03-2020 18:16, Alex Peshkoff via Firebird-devel wrote:
On 2020-03-04 20:01, Mark Rotteveel wrote:
What is the purpose of introducing yet another datatype called
EXTENDED TIME/TIMESTAMP WITH TIME ZONE?
Help users missing ICU on the client work with time zones.
I think this is extremely confusing, making both SQL
No. Use of them is very restricted - the _ONLY_ place where they can
be used in SQL is SET BIND statement.
I had missed that, but why not just always put those two bytes in the
WITH TIME ZONE data?
Yes, we thought about such way. Main reason not to go that way for me
was that Adriano was strongly against that and I did not want to
continue that discussion.
Other reasons is that this "extended" slution is sooner of all temporal.
ICU becomes a natural part of all OSes (for posix that already hapepned
a few years ago, new windows also contains ICU). I.e. long term
everything will work just fine by default with std type. But we need
something working today (hard to imagine a noise @sql.ru when people
noticed that they receive GMT-time using fb4), therefore such temporal
extension.
But due to it's temporal nature always adding 2 more bytes may really
appear wrong, is not it?
Why introduce an extra datatype, when you could also do it always for
this new data type (the WITH TIME ZONE types have 2 bytes of padding
anyway).
That's also not completely true. If you use gpre - yes, that's correct.
But in SQL message format each field is always followed by NULL
indicator which is exactly 2 bytes and ideally fits after WITH TIME ZONE
data.
and the wire protocol more convoluted.
Did not notice it when adding datatype :-) Certainly one more type
means a bit efforts in XDR but that's not more than a few lines of code.
To me, this commit[1] looks like a lot more than just a few lines of code
Stop-stop - I've talked about wire protocol support efforts! Cerainly in
complete commit there is some more code except wire protocol ;)
To be precise - more than a half are changes in tables of arythmetic
results, they quickly answer a question what is result datatype when one
performs some OP on a pair of datatypes, for example subtracts date from
date. This is a set of 2-dimensional arrays, and yes - they are rather
large.
Firebird-Devel mailing list, web interface at
https://lists.sourceforge.net/lists/listinfo/firebird-devel