• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1973
  • Last Modified:

I am also trying to connect MS Access to NCR Teradata. I have not been able to connect through ADODB connection - when I try to open the connection I get this error: "Can't find host [MyServer]Cop1

I am trying to connect MS Access to NCR Teradata.  Ultimately I want to use Access to send pass through queries to teradata and receive the results.  I have not been able to connect through ADODB connection.

Error1:  "Can't find host [MyServer]Cop1"  
Error2:  "10065 WSA E HostUnreach: The teradata server can't currently be reached over this network"

I'm trying to use a standard ADODB connection but it doesn't seem to be working...
Option Compare Database
Option Explicit
Public Sub RunPassThroughQuery() '(SQLString As String)
    Dim oConn As ADODB.Connection
    Dim oRec As ADODB.Recordset
    Dim conStr As String   'connection string
    Dim rConn As ADODB.Connection
    Dim strDir As String
    On Error GoTo ErrorHandle
    Set rConn = CurrentProject.Connection
    Set oConn = New ADODB.Connection
    Set oRec = New ADODB.Recordset
    With oConn
        .CursorLocation = adUseClient
        .CommandTimeout = 3600
        .Open "Driver={Teradata};DBCName=[P5450];Database=[IW_Deflt_ProdDB_V];Connect Timeout=3600;Uid= abc;Pwd= 123"
    End With
    'Run the SQL command on the Teradata warehouse
    'oRec.Open SQLString, oConn 'set other attributes if necessary
    If oRec.RecordCount < 1 Then
        MsgBox "There were no records to import.  This is probably a bug, please contact development."
        Exit Sub
    End If
    Exit Sub
MsgBox Error()
Exit Sub
End Sub

Open in new window

  • 4
2 Solutions
BryceMTAuthor Commented:
I read through that post already -

I need help correcting the connection string or finding some way to establish a connection to Teradata through MS Access.  So far, I have successfully execute SQL pass through queries in my Access DB, but I have not been able to open up a connection in VBA with ADODB connection.
Rey Obrero (Capricorn1)Commented:
try this format from

oConn.Open "Provider=Teradata;" & _
           "DBCName=MyDbcName;" & _
           "Database=MyDatabaseName;" & _
           "Uid=myUsername;" & _



Easily Design & Build Your Next Website

Squarespace’s all-in-one platform gives you everything you need to express yourself creatively online, whether it is with a domain, website, or online store. Get started with your free trial today, and when ready, take 10% off your first purchase with offer code 'EXPERTS'.

BryceMTAuthor Commented:
After I tried this format:

oConn.Open "Provider=Teradata;" & _
           "DBCName=MyDbcName;" & _
           "Database=MyDatabaseName;" & _
           "Uid=myUsername;" & _

I'm getting this error:
"Provider cannot be found - it may not be properly installed."
BryceMTAuthor Commented:
I might need to install a Teradata driver...  Has anybody worked with installing teradata drivers in ms access?
BryceMTAuthor Commented:
For now I am using ADO connection object referencing ODBC DSN...

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

  • 4
Tackle projects and never again get stuck behind a technical roadblock.
Join Now