Skip to content

Add support for get / show timezone #3255

Description

@avantgardnerio

Is your feature request related to a problem or challenge? Please describe what you are trying to do.

Presently, show timezone does not work:

DataFusion CLI v11.0.0
❯ show time zone;
NotImplemented(“SHOW time.zone not implemented. Supported syntax: SHOW <TABLES>“)

Describe the solution you'd like

Instead, I would like:

show timezone;

To always return 'utc'.

set timezone 'utc';

Should succeed.

set timezone 'UTC+08`;

should return an error.

and

set timezone 'US/Mountain`;

should return the same error.

This should:

  1. make the work @waitingkuo is doing easier by ignoring non-UTC zones for now
  2. Stay technically compatible with ANSI SQL & postgres (as long as postgres is set to UTC)
  3. allow the option to implement timezones at a future date.

PS:

Do the same for select current_setting('TIMEZONE')

Describe alternatives you've considered

  • Having to violate ANSI SQL
  • Having to tackle timezones while implementing timestamp without timezone

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions