Selecting data from a Fox Pro based LS

  • Greetings,

    I've got a linked server that points to a directory that contains Fox Pro files. I'm using an ODBC driver. From the EM I can see the tables. From isql I use this query to try and access the data:

    SELECT * FROM UNDERWRITING...RS_INV03 WHERE MEMB_NUM='01804-00'

    This produces the following error:

    Server: Msg 7313, Level 16, State 1, Line 4

    Invalid schema or catalog specified for provider 'MSDASQL'.

    OLE DB error trace [Non-interface error: Invalid schema or catalog specified for the provider.].

    Since I'm not familiar with fox I'm not sure what the catalog would be. Has anyone run up on this one?

    Cheers

  • Thanks you, thank you, thank you! I searched the MS site but this doc never came up. The key was this:

    SQLCommand="SELECT * FROM OPENQUERY(VFP,'SELECT * FROM CUSTOMER')"

    I used:

    SELECT * FROM OPENQUERY(UNDERWRITING,'SELECT * FROM RS_INV03')

    and I get data. I need to add a where clause but I'll deal with that. Thanks again. You really helped me out here.

    Cheers

  • If anyone needs it here is a sample of how to use the where clause. You simply use double quotes.

    SELECT * FROM OPENQUERY(UNDERWRITING,'SELECT * FROM RS_INV03 where memb_num="01804-00"')

    Cheers

Viewing 4 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply