I install netezza ODBC drivers and configure data sources(ODBC) in Adminitstrative tools by add user DSN as NZSQL.
Next I connect with Visual studio 2013 using DSN in Server Explorer, in Datasource I select Microsoft ODBC data source and data provider I select .Net framework data provider for ODBC. The connection test is successful and I copy connectionstring from connection string in server explorer and paste it in web.config:
<add name="cn" connectionString="Dsn=NZSQL;Driver={NetezzaSQL};uid=kbanke2e"/>
When I compile the error is:
Additional information: A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server
I successfully managed to create a Netezza datasource in VS2013 by specifying the full connection string manually:
The only problem I had was due to VS looking for the 32-bit driver (
nsqlodbc.dll
) inC:\Windows\SysWOW64
. Initially I only had the 64-bit driver installed.