Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Netezza “[08S01] Communication link failure” Loading External Data

Am getting:

ERROR [HY008] Operation canceled ERROR [08S01] Communication link failure

When trying to upload external .txt file to Netezza database. I have done this in the past (just last week), but today receive this error. Am able to connect to DB, ran truncate and create table statements for the loading of this data, can select, etc...But yet no luck loading. It's around 200K records and here is my code:

INSERT INTO PTG_ITO_ETL.FINANCE_TY15_RT_TPG
SELECT * FROM EXTERNAL 'C:\\Users\\Documents\\Data Sources\\Finance_FY15_RT\\SBTPG\\TPG_INTUIT_RT_PRODIV_20150214.TXT'
USING
(
    MAXERRORS 1
    DATESTYLE 'MDY'
    DATEDELIM '/'
    BOOLSTYLE 'Y_N'
    Y2BASE 2000
    ENCODING 'internal'
    SKIPROWS 1
    REMOTESOURCE 'ODBC'
    ESCAPECHAR '\'
)

Have tried solution from only other post I could find on the subject:

ERROR [08S01] Communication link failure while inserting data in to external table in netezza

"I have found in Windows 7 and Windows Server 2008 R2 TCP Chimney Settings were the culprit.

http://blogs.dirteam.com/blogs/sanderberkouwer/archive/2008/05/15/backward-compatible-networking-with-server-core.aspx

The Follwing Commands Fixed this issue for me:

netsh interface tcp set global rss=disabled
netsh interface tcp set global chimney=disabled
netsh interface tcp set global autotuning=disabled"

But, to no avail. Don't know what is causing this issue? Am on windows 7 using Aginity, Netezza version 7.0.4 Thanks!

Thanks, Craig

like image 968
thagraybush Avatar asked Oct 20 '22 17:10

thagraybush


2 Answers

Please try the following and see if it errors

    SELECT * FROM EXTERNAL 'C:\\Users\\Documents\\Data Sources\\Finance_FY15_RT\\SBTPG\\TPG_INTUIT_RT_PRODIV_20150214.TXT'
(field1 varchar(20000))
    USING
    (
        MAXERRORS 1
        Delim 199
        DATESTYLE 'MDY'
        DATEDELIM '/'
        BOOLSTYLE 'Y_N'
        Y2BASE 2000
        ENCODING 'internal'
        SKIPROWS 1
        REMOTESOURCE 'ODBC'
        ESCAPECHAR '\'
    )
like image 163
Niederee Avatar answered Oct 22 '22 23:10

Niederee


Appreciate the Help from @ScottMcG, after downloading the latest Netezza Driver (7.0.4.7) I was able to complete this job. Still errored out (with same error) a couple times but also worked many with extensive testing.

I read another post similar and this error seems common the larger the records go. I read one where person was using an external table with a million+ records and errored out every time. If need be I (you) may need to split the data into smaller external tables for loading to one table/DB. Seems to start having problems around 200k+.

This is also from my laptop, so maybe much higher if you were on a box inside the Data Center. I would suggest the driver upgrade and then splitting to smaller files if necessary.

Thanks All!

like image 44
thagraybush Avatar answered Oct 22 '22 23:10

thagraybush