Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17


Can SQLServer use Btrieve tables...

Posted on 1999-06-29
Medium Priority
Last Modified: 2008-03-03
I have SQLServer set up and need to replicate data from a
Btrieve database (used by a piece of software called primavera).  Is there any way I can get it to do the replication?  I don't have any admin tools for Btrieve so I can't go and tell it to be a publisher (at least, not to my knowledge).

I have gotten MS Access to use the tables by linking them though.

Question by:sloans030499
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions

Expert Comment

ID: 1096000
Do you only have to do this once (as in converting the data) or will both databases be used, Btrieve sending data to SQL replication like?

Author Comment

ID: 1096001
Both will be used.  Replication will occur once a day.

We want to (daily) pull from the btrieve to the SQL Server for performance reasons.

Accepted Solution

rdrrichards earned 800 total points
ID: 1096002
If you can set up a system DSN to the BTrieve DB then you can use Distributed Queries (using OPENQUERY or OPENROWSET) to pull the data from BTrieve and insert it into SQL Server tables.

I use them to retrieve data from DB2 tables on an AS/400 on an hourly basis.



This is one way for SQL Server to 'use' BTrieve tables.

If you have any OLE DB drivers for BTrieve you can set up the BTrieve file as a Linked Server to the SQL Server DB. This is done automatically when you run either the OPENQUERY or OPENROWSET.

Check out the SQL Online Books for more info.

Hope this points you in the right direction.

Simplifying Server Workload Migrations

This use case outlines the migration challenges that organizations face and how the Acronis AnyData Engine supports physical-to-physical (P2P), physical-to-virtual (P2V), virtual to physical (V2P), and cross-virtual (V2V) migration scenarios to address these challenges.


Author Comment

ID: 1096003
I tried it:

Seems like the OPENQUERY command is recognized, but it doesn't like any of the syntax, even the stuff directly from the MSDN Online Books.

I even tried the sp_addlinkedserver procedure and it couldn't find it.  We are running SQLServer 6.5

Does that make a difference?


Expert Comment

ID: 1096004
Yes, that makes a big difference. The OPENQUERY and sp_addlinkedserver only work with SQL Server 7.0. Sorry, I assumed you had the latest version.

I don't think there is a way for SQL Server 6.5 to use the tables in your BTrieve DB files. Is it possible for you to upgrade to 7.0?

If it's possible for Primavera to dump to data to a text file, you BCP it into SQL Server. That could get complicated, though.

Good luck, and sorry about the confusion.


Expert Comment

ID: 6873358

This question was awarded, but never cleared due to the JSP-500 errors of that time.  It was "stuck" against userID -1 versus the intended expert whom you awarded.  This corrects the problem and the expert will now receive these points; points verified.

Please click on your Member Profile and select "View Question History" to navigate through any open or locked questions you may have to update and finalize them.  If you are an EE Pro user, you can also choose Power Search to find all your open questions.

This is the Community Support link, if help is needed, along with the link to All Topics which reflects many TAs recently added.  You'll also find a link there for Experts who wish to participate in the cleanup effort of old and abandoned questions.
Thank you,
Moderator @ Experts Exchange

Featured Post

Migrating Your Company's PCs

To keep pace with competitors, businesses must keep employees productive, and that means providing them with the latest technology. This document provides the tips and tricks you need to help you migrate an outdated PC fleet to new desktops, laptops, and tablets.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article explains how to reset the password of the sa account on a Microsoft SQL Server.  The steps in this article work in SQL 2005, 2008, 2008 R2, 2012, 2014 and 2016.
When trying to connect from SSMS v17.x to a SQL Server Integration Services 2016 instance or previous version, you get the error “Connecting to the Integration Services service on the computer failed with the following error: 'The specified service …
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.
Viewers will learn how to use the SELECT statement in SQL and will be exposed to the many uses the SELECT statement has.

664 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question