Importing from depricated DBs

  • I've got a Foxpro DB that I need to import into SQL 2005. Does anyone have any links to even doing a full Foxpro table dump in 64-bit? I've seen some forums were people where writing their own 64-bit versions of dbf readers where it does nothing more than dump the files, but they didn't have their code posted. I don't need to run any queries, just a dump to txt of the sort.

  • Disclaimer:

    I have not worked with Foxpro DB. However, if you can open the dBase files in MS ACCESS, then this solution might work.

    You can put all your dBase files in a folder and define a Linked Server in you SQL Server instance. An example:

    EXEC sp_addlinkedserver

    'myDbaseDB',

    'Jet 4.0',

    'Microsoft.Jet.OLEDB.4.0',

    'C:\kaushal\dBaseFILES',

    NULL,

    'dBase IV'

    GO

    .. then define a login information for the newly defined linked server ...

    exec sp_addlinkedsrvlogin

    @rmtsrvname = 'myDbaseDB',

    @useself = false,

    @locallogin = NULL,

    @rmtuser = NULL,

    @rmtpassword = NULL

    GO

    And you are good to go.. Let's say you have a dBase file called ORDERS.dbf , you should be able to run a query like this:

    select * from openquery(myDbaseDB, 'select * from ORDERS')

Viewing 2 posts - 1 through 1 (of 1 total)

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