You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Whenever I try to run a query to pull a date record of type datetime64 that is less than 1960, I get the following error:
ClickHouse Connect Error
clickhousedb error: year 584556016 is out of range
This may be triggered by:
Issue 1002 - The database returned an unexpected error.
The same query runs well on the clickhouse database using tabix, but fails on Apache superset
Steps to reproduce the bug
Go to SQL -> SQL Lab
Choose any clickhouse database
Write a query to pull date records (of data type datetime64) before '1970'
Describe the bug
Whenever I try to run a query to pull a date record of type datetime64 that is less than 1960, I get the following error:
ClickHouse Connect Error
clickhousedb error: year 584556016 is out of range
This may be triggered by:
Issue 1002 - The database returned an unexpected error.
The same query runs well on the clickhouse database using tabix, but fails on Apache superset
Steps to reproduce the bug
Screenshot
Expected behaviour
The query should produce a result table
Code example
clickhouse-connect and/or ClickHouse server logs
superset_app | 2023-06-15 14:51:18,369:INFO:superset.sql_lab:Query 60: Executing 1 statement(s)
superset_app | Query 60: Set query to 'running'
superset_app | 2023-06-15 14:51:18,369:INFO:superset.sql_lab:Query 60: Set query to 'running'
superset_app | Query 60: Running statement 1 out of 1
superset_app | 2023-06-15 14:51:18,425:INFO:superset.sql_lab:Query 60: Running statement 1 out of 1
superset_app | SupersetErrorsException
superset_app | Traceback (most recent call last):
superset_app | File "/usr/local/lib/python3.8/site-packages/flask/app.py", line 1517, in full_dispatch_request
superset_app | rv = self.dispatch_request()
superset_app | File "/usr/local/lib/python3.8/site-packages/flask/app.py", line 1503, in dispatch_request
superset_app | return self.ensure_sync(self.view_functions[rule.endpoint])(**req.view_args)
superset_app | File "/usr/local/lib/python3.8/site-packages/flask_appbuilder/security/decorators.py", line 95, in wraps
superset_app | return f(self, *args, **kwargs)
superset_app | File "/app/superset/views/base_api.py", line 122, in wraps
superset_app | raise ex
superset_app | File "/app/superset/views/base_api.py", line 113, in wraps
superset_app | duration, response = time_function(f, self, *args, **kwargs)
superset_app | File "/app/superset/utils/core.py", line 1586, in time_function
superset_app | response = func(*args, **kwargs)
superset_app | File "/app/superset/views/base_api.py", line 85, in wraps
superset_app | return f(self, *args, **kwargs)
superset_app | File "/app/superset/utils/log.py", line 266, in wrapper
superset_app | value = f(*args, **kwargs)
superset_app | File "/app/superset/sqllab/api.py", line 256, in execute_sql_query
superset_app | command_result: CommandResult = command.run()
superset_app | File "/app/superset/sqllab/commands/execute.py", line 120, in run
superset_app | raise ex
superset_app | File "/app/superset/sqllab/commands/execute.py", line 102, in run
superset_app | status = self._run_sql_json_exec_from_scratch()
superset_app | File "/app/superset/sqllab/commands/execute.py", line 157, in _run_sql_json_exec_from_scratch
superset_app | raise ex
superset_app | File "/app/superset/sqllab/commands/execute.py", line 152, in _run_sql_json_exec_from_scratch
superset_app | return self._sql_json_executor.execute(
superset_app | File "/app/superset/sqllab/sql_json_executer.py", line 111, in execute
superset_app | raise SupersetErrorsException(
superset_app | superset.exceptions.SupersetErrorsException: [SupersetError(message='clickhousedb error: year 584556013 is out of range', error_type=<SupersetErrorType.GENERIC_DB_ENGINE_ERROR: 'GENERIC_DB_ENGINE_ERROR'>, level=<ErrorLevel.ERROR: 'error'>, extra={'engine_name': 'ClickHouse Connect', 'issue_codes': [{'code': 1002, 'message': 'Issue 1002 - The database returned an unexpected error.'}]})]
Configuration
Environment
The text was updated successfully, but these errors were encountered: