You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2021/03/03 09:53:10 UTC
[GitHub] [superset] nikolagigic commented on a change in pull request #13294: feat(explore): Postgres datatype conversion
nikolagigic commented on a change in pull request #13294:
URL: https://github.com/apache/superset/pull/13294#discussion_r586272123
##########
File path: superset/db_engine_specs/postgres.py
##########
@@ -45,6 +47,96 @@ class PostgresBaseEngineSpec(BaseEngineSpec):
engine = ""
engine_name = "PostgreSQL"
+ column_type_mappings = (
+ (
+ re.compile(r"^smallint", re.IGNORECASE),
+ types.SMALLINT,
+ utils.GenericDataType.NUMERIC,
Review comment:
@ktmud Yes, it could've been mapped as you proposed. The reason behind the current way is that if we get multiple matches we can prioritise those at the start of the list without necessarily sorting the results for the most part.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org