Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1XWQDn-0005BI-0P for pgsql-odbc@arkaria.postgresql.org; Tue, 23 Sep 2014 13:33:35 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1XWQDm-0002n4-D3 for pgsql-odbc@arkaria.postgresql.org; Tue, 23 Sep 2014 13:33:34 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1XWQDl-0002mt-Ji for pgsql-odbc@postgresql.org; Tue, 23 Sep 2014 13:33:33 +0000 Received: from out3-smtp.messagingengine.com ([66.111.4.27]) by makus.postgresql.org with esmtps (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1XWQDg-0001ni-Rd for pgsql-odbc@postgresql.org; Tue, 23 Sep 2014 13:33:31 +0000 Received: from compute6.internal (compute6.nyi.internal [10.202.2.46]) by gateway2.nyi.internal (Postfix) with ESMTP id B91FE2075B for ; Tue, 23 Sep 2014 09:33:27 -0400 (EDT) Received: from frontend1 ([10.202.2.160]) by compute6.internal (MEProxy); Tue, 23 Sep 2014 09:33:27 -0400 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=aklaver.com; h= message-id:date:from:mime-version:to:cc:subject:references :in-reply-to:content-type:content-transfer-encoding; s=mesmtp; bh=p1CqR0w65iU5VVSohTYIQ31jalQ=; b=PxOGfY7OD7fRs6Y6bQJvz2D6MIHL oAtGtCjS0E4chf7dKt9Qv+O8lf3PWu8oFFv14LUmfOlQQBri0n6ltO6iyD4yYGLK DXUO5du06BA4wv0IROXU8+rxuMdvj5cb0DiDhV8jvnwyhrRvBo+jfkOR4lVsk/Lr ZlJqRSGb0YED4/k= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=message-id:date:from:mime-version:to:cc :subject:references:in-reply-to:content-type :content-transfer-encoding; s=smtpout; bh=p1CqR0w65iU5VVSohTYIQ3 1jalQ=; b=liH4Aje20NLVnQDJigLLCI6OSkU7kC3A487m5ErB52Rn0zA9Dhf9+z bfIZeo5hiIoC4Nr05NFZn7GsUFzPXq1Uxg5M8TGLui0Tc9gRmYsGegbDliiCCzh6 6CEl1L24YFWQ5Eeid1L0FfL05Auwir3wi2YEX7E7k9blS38v9cfME= X-Sasl-enc: Xb+2o0kGXOlxOJHeOUz1mj8c4q5fz48p/LOlmWVgT+L3 1411479207 Received: from [192.168.1.5] (unknown [174.21.177.1]) by mail.messagingengine.com (Postfix) with ESMTPA id 3972EC008FC; Tue, 23 Sep 2014 09:33:27 -0400 (EDT) Message-ID: <542176A6.7090608@aklaver.com> Date: Tue, 23 Sep 2014 06:33:26 -0700 From: Adrian Klaver User-Agent: Mozilla/5.0 (X11; Linux i686; rv:24.0) Gecko/20100101 Thunderbird/24.6.0 MIME-Version: 1.0 To: David Hedberg , Heikki Linnakangas CC: pgsql-odbc@postgresql.org Subject: Re: [PATCH] Return the correct column names in SQLTables References: <54214180.90807@vmware.com> In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Pg-Spam-Score: -2.7 (--) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-odbc Precedence: bulk Sender: pgsql-odbc-owner@postgresql.org On 09/23/2014 03:46 AM, David Hedberg wrote: > On Tue, Sep 23, 2014 at 11:46 AM, Heikki Linnakangas > wrote: >> On 08/09/2014 07:29 PM, David Hedberg wrote: >>> >>> This patch was needed to be able to >>> list the tables when trying to import data in Excel 2010/PowerPivot. >> >> >> Hmm. According to the ODBC documentation on SQLTables: >> >> "The following columns have been renamed for ODBC 3.x. The column name >> changes do not affect backward compatibility because applications bind by >> column number." >> >> So, arguably this is a bug in Excel/PowerPivot, if it's binding by column >> name rather than number. But it doesn't really matter, we should fix the >> column names anyway. > > To the extent the problem falls on the driver side, what do you think > about the proposed patch? Feel free to amend it or throw it away if > you have a better fix. > >>> A somewhat unrelated question: >>> There is one more "fix" needed to get the import of data in PowerPivot >>> working properly, and that is because PowerPivot insists on creating >>> the query with mssql-style quotes. (select [schema].[table].* instead >>> of select "schema"."table".* ..). >> >> >> Ugh. How does that work with any other ODBC driver than MS SQL Server? >> > > I don't really use these products usually so I can't really comment, > but as far as I could tell there was no attempt made to get the > correct quoting style from the driver. I guess I will keep my ugly > hack for this to myself though unless asked otherwise. :-) This seems to be generic problem with PowerPivot and non-MS data sources. Some searching found a possible solution, use the Power Query add in: http://www.microsoft.com/en-us/download/details.aspx?id=39379 http://office.microsoft.com/en-us/excel-help/introduction-to-microsoft-power-query-for-excel-HA104003940.aspx > >> - Heikki >> > > / David > > -- Adrian Klaver adrian.klaver@aklaver.com -- Sent via pgsql-odbc mailing list (pgsql-odbc@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-odbc