Denny Lee

Ramblings of a data dork: from BI and Big Data to Travel and Food

Padding zero-length string data with HiveODBC

One of the more esoteric error messages that you may receive from the HiveODBC driver connection is:

SQL_ERROR Failed to get data for column zu

When connecting to Hive using the HiveODBC driver using a linked server connection, the full error message looks something like:

OLE DB provider “MSDASQL” for linked server “MySQLHive” returned message “SQL_ERROR Failed to get data for column zu”.
OLE DB provider “MSDASQL” for linked server “MySQLHive” returned message “SQL_ERROR get signed long int data failed for column 9. Column index out of bounds.”.
OLE DB provider “MSDASQL” for linked server “MySQLHive” returned message “Option value changed”.
Msg 7330, Level 16, State 2, Line 1
Cannot fetch a row from OLE DB provider “MSDASQL” for linked server “MySQLHive”.

Thanks to some digging by James Baker and Dave Mariani (@dmariani, VP Engineering at Klout), we realized that the ODBC Provider for Hive might not correctly handle zero-length string data returned from Hive.

As noted in the SQL Server Analysis Services to Hive case study, to avoid these issues, avoid returning empty strings from Hive.  For more information, please reference page 12 of the case study.

Hope that helps!

About dennyglee

dork, scribe, geek, Microsoft data dork, ultimate frisbee fan, mountain climber (barely!),... occasionally awake

3 Comments on “Padding zero-length string data with HiveODBC

  1. Pingback: Windows Azure and Cloud Computing Posts for 10/8/2012+ - Windows Azure Blog

  2. William
    October 9, 2012

    Thanks! I’d been digging into this for a bit now. Great timing

  3. robert
    February 28, 2013

    the hiveodbc driver is not the same driver that is available from msft to connect to hadoop on the azure platform. is this correct? however, once the hiveodbc driver is installed it will run via thrift and allow for querying via the linked server in sql server?

    thanks,
    -robert

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s

Information

This entry was posted on October 9, 2012 by in BigData and tagged , , .

Professional Microsoft SQL Server 2012 Analysis Services with MDX and DAX

Analysis Services Multidimensional and Tabular Reference all in one handy book!

@dennylee

Enter your email address to follow this blog and receive notifications of new posts by email.

Join 2,002 other followers

Copyright

Copyright © 2012 Denny G Lee - All Rights Reserved
Follow

Get every new post delivered to your Inbox.

Join 2,002 other followers

%d bloggers like this: