Re: [Firebird-devel] Current timestamp without timezone in given timezone

2021-02-13 Thread Dimitry Sibiryakov
13.02.2021 08:13, Mark Rotteveel wrote: Maybe we need a TRUNCATE_TIME_ZONE function, which for a TIME/TIMESTAMP WITH TIME ZONE will return a WITHOUT TIME ZONE equivalent with the same wallclock time. We could borrow general-purpose TRUNC() from Oracle but personally I would prefer standard C

Re: [Firebird-devel] Current timestamp without timezone in given timezone

2021-02-13 Thread Mark Rotteveel
On 13-02-2021 11:20, Dimitry Sibiryakov wrote: 13.02.2021 08:13, Mark Rotteveel wrote: Maybe we need a TRUNCATE_TIME_ZONE function, which for a TIME/TIMESTAMP WITH TIME ZONE will return a WITHOUT TIME ZONE equivalent with the same wallclock time.   We could borrow general-purpose TRUNC() fro

Re: [Firebird-devel] Current timestamp without timezone in given timezone

2021-02-13 Thread Dimitry Sibiryakov
13.02.2021 12:00, Mark Rotteveel wrote: Firebird already has a TRUNC. That's good, no need for another reserved word. The current behaviour of CAST to me makes more sense than the behaviour defined in the standard. I can see that there might be cases when you might want the time without tim

Re: [Firebird-devel] Current timestamp without timezone in given timezone

2021-02-13 Thread Mark Rotteveel
On 13-02-2021 12:06, Dimitry Sibiryakov wrote: 13.02.2021 12:00, Mark Rotteveel wrote: Firebird already has a TRUNC.   That's good, no need for another reserved word. The current behaviour of CAST to me makes more sense than the behaviour defined in the standard. I can see that there might

Re: [Firebird-devel] Current timestamp without timezone in given timezone

2021-02-13 Thread Dimitry Sibiryakov
13.02.2021 13:41, Mark Rotteveel wrote: However if we're going to change this, we need to ensure that data type binding to WITHOUT TIME ZONE types will still work correctly (AFAIK, it currently uses the same code path as a cast), that is: render in the session time zone. Unfortunately it has

Re: [Firebird-devel] Current timestamp without timezone in given timezone

2021-02-13 Thread Mark Rotteveel
On 13-02-2021 13:52, Dimitry Sibiryakov wrote: 13.02.2021 13:41, Mark Rotteveel wrote: However if we're going to change this, we need to ensure that data type binding to WITHOUT TIME ZONE types will still work correctly (AFAIK, it currently uses the same code path as a cast), that is: render i

[Firebird-devel] [FB-Tracker] Created: (CORE-6485) Provide time zone ids constants in public headers

2021-02-13 Thread Dimitry Sibiryakov (JIRA)
Provide time zone ids constants in public headers - Key: CORE-6485 URL: http://tracker.firebirdsql.org/browse/CORE-6485 Project: Firebird Core Issue Type: Improvement Components: API

Re: [Firebird-devel] Current timestamp without timezone in given timezone

2021-02-13 Thread Adriano dos Santos Fernandes
Em sáb, 13 de fev de 2021 10:01, Mark Rotteveel escreveu: > On 13-02-2021 13:52, Dimitry Sibiryakov wrote: > > 13.02.2021 13:41, Mark Rotteveel wrote: > >> However if we're going to change this, we need to ensure that data > >> type binding to WITHOUT TIME ZONE types will still work correctly > >