From notifications-return-40550-archive-asf-public=cust-asf.ponee.io@superset.apache.org Thu May 7 17:39:23 2020 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [207.244.88.153]) by mx-eu-01.ponee.io (Postfix) with SMTP id D51D818062B for ; Thu, 7 May 2020 19:39:22 +0200 (CEST) Received: (qmail 18654 invoked by uid 500); 7 May 2020 17:39:22 -0000 Mailing-List: contact notifications-help@superset.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@superset.apache.org Delivered-To: mailing list notifications@superset.apache.org Received: (qmail 18608 invoked by uid 99); 7 May 2020 17:39:22 -0000 Received: from ec2-52-202-80-70.compute-1.amazonaws.com (HELO gitbox.apache.org) (52.202.80.70) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 07 May 2020 17:39:22 +0000 From: =?utf-8?q?GitBox?= To: notifications@superset.apache.org Subject: =?utf-8?q?=5BGitHub=5D_=5Bincubator-superset=5D_dpgaspar_commented_on_pull_r?= =?utf-8?q?equest_=239752=3A_fix=28mssql=29=3A_CAST_with_AT_produces_stateme?= =?utf-8?q?nts_with_syntax_errors?= Message-ID: <158887316224.26397.16054945346258806836.asfpy@gitbox.apache.org> Date: Thu, 07 May 2020 17:39:22 -0000 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit References: In-Reply-To: dpgaspar commented on pull request #9752: URL: https://github.com/apache/incubator-superset/pull/9752#issuecomment-625398453 @bkyryliuk we have a simple query construction here: https://github.com/apache/incubator-superset/blob/master/superset/db_engine_specs/base.py#L397 and it's being used for MSSQL. Is something similar what you're looking for? @mistercrunch also mentioned that using a `WRAP_SQL` is inefficient on some engines. My plan is, if feasible/simple change `WRAP_SQL` to something like `FORCE_TOP` and doing the best to identify non aliased functions and warn the user about it. This last one could be tricky for statements like: `SELECT COL1, COL1, CAST(COL3 AS DATETIME) AT TIME ZONE "SOME_TZ", COL4` `sqlparse` get seems to get lost on `AT` and does not identify `COL4` has a column. ---------------------------------------------------------------- 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