Results 1 to 6 of 6
  1. #1
    Join Date
    Feb 2005
    Location
    Milwaukee, WI
    Posts
    105

    Unanswered: Linked Server to Visual FoxPro Not Work

    I've downloaded and installed the latest VFPOLEDB (12/04) on 2 separate SQL Server boxes.

    In both cases, If I connect to SQL Server with Query Analyzer as (local) while on a box, the linked server to my foxpro database works fine with openquery().

    However, If I'm at one box and attached to SQL Server on the other box, the openquery() fails.

    Here's some particulars:
    ---
    EXEC sp_addlinkedserver
    @server='VFP',
    @provider='VFPOLEDB',
    @datasrc='\\hdmcpdctis1\tisrnddata\',
    @srvproduct='Visual FoxPro'

    --this works on either (local) box
    SELECT *
    FROM OPENQUERY(VFP, 'select * from tislists')
    Go

    --but, the same openquery() above doesn't work if the box I'm running it from is attached to the SQL Server on the other box. I get:

    Server: Msg 7302, Level 16, State 1, Line 1
    Could not create an instance of OLE DB provider 'VFPOLEDB'.
    OLE DB error trace [Non-interface error: CoCreate of DSO for VFPOLEDB returned 0x80040154].
    =====================
    One other approach I tried that works while on the (local) box, but fails when attached to the SQL Server on the other box:

    select * from openrowset('MSDASQL',
    'Driver=Microsoft Visual FoxPro Driver;SourceType=DBF;SourceDB= \\hdmcpdctis1\tisrnddata\ ',
    'select * from [tislists.DBF]')


    With error:
    Server: Msg 7399, Level 16, State 1, Line 1
    OLE DB provider 'MSDASQL' reported an error.
    [OLE/DB provider returned message: [Microsoft][ODBC Driver Manager] Driver does not support this function]
    OLE DB error trace [OLE/DB Provider 'MSDASQL' IDBInitialize::Initialize returned 0x80004005: ].
    ===========================

    Any Help is greatly appreciated! Thanks,

    peter

  2. #2
    Join Date
    Oct 2003
    Posts
    57

    I have the same problem

    Hi,

    Do you still have this problem? If not, how did you get around it? I am experiencing the exact same thing and am quite confused at this point...

    Thanks!

  3. #3
    Join Date
    Nov 2004
    Location
    on the wrong server
    Posts
    8,835
    Provided Answers: 6
    At my last job I handled a few linked Visual FoxPro linked serves from a SQL 7 database and I did'nt encounter this but let me ask you 2 questions.

    1. Are you able query any database in BOX B from BOX A?

    2. Have you tried querying using the 4 part name? linked_server_name.catalog.schema.object_name
    “If one brings so much courage to this world the world has to kill them or break them, so of course it kills them. The world breaks every one and afterward many are strong at the broken places. But those that will not break it kills. It kills the very good and the very gentle and the very brave impartially. If you are none of these you can be sure it will kill you too but there will be no special hurry.” Earnest Hemingway, A Farewell To Arms.

  4. #4
    Join Date
    Oct 2003
    Posts
    57
    Answers to the questions:

    1) Yes I can query some DB's from BOX A while on BOX B, the success depends on what authentication type the SQL Server instance is registered with in my enterprise manager

    2) I have not tried querying with the 4 part name, I have only gotten as far as trying to view the list of tables through enterprise manager when I get the error

    Thanks

  5. #5
    Join Date
    Nov 2004
    Location
    on the wrong server
    Posts
    8,835
    Provided Answers: 6
    Can you see the tables is enterprise manager on the local box?

    If not you have problem with your linked server definition. I am leaving for the day but I can check back on this this evening if I am not totally dead to the world.
    Last edited by Thrasymachus; 02-24-05 at 14:50.
    “If one brings so much courage to this world the world has to kill them or break them, so of course it kills them. The world breaks every one and afterward many are strong at the broken places. But those that will not break it kills. It kills the very good and the very gentle and the very brave impartially. If you are none of these you can be sure it will kill you too but there will be no special hurry.” Earnest Hemingway, A Farewell To Arms.

  6. #6
    Join Date
    Oct 2003
    Posts
    57
    I can see the tables in EM on the local box, just not from the remote box.

    Good luck on the interview...

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •